View Single Post
Old 09-28-2012, 02:43 PM   PM User | #5
sanidhya09
New to the CF scene

 
Join Date: Sep 2012
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
sanidhya09 is an unknown quantity at this point
Quote:
Originally Posted by devnull69 View Post
This is not EXACTLY what you want, is it?
Code:
var b=[];
b[0]="sector4";
b[1]="sector5";
b[2]="sector6";
var result = "";
for(var j=0;j<b.length;j++)
{
   result += b[j];
}
document.getElementById("demo").value = result;
function Noida()
{
var a=new Array;
a[0]="sector1";
a[1]="sector2";
a[2]="sector3";
var i;
for(i=0;i<=((a.length)-1);i++){
document.getElementById("demo").innerHTML=a[i];
//document.write(a[i]);
}
}
I want to print all the array value in the "same" document
in <p id="demo"></p>
sanidhya09 is offline   Reply With Quote