Hi,
I try to make a table with at least 3Columns* 3 Rows.
the table is when I upload the picture, the first picture would go to
first column/ first row...
Second pictures would go second column/first row
Third one go third column/first row...
Fourth would go first column/second row...so so on..
I got the code here..
- HTML: Select all
var Urls = new Array();
var Imgs = new Array();
function showTags(theTag,thePlace) {
function getTag(tag) {
var tmp='';
xx=x[i].getElementsByTagName(tag);
try { tmp=xx[0].firstChild.data; }
catch(er) { tmp=''; }
return(tmp);
}
var xx; var x; var txt;
x = xmlDoc.getElementsByTagName(theTag);
txt='<table border="0" cellPadding="2" width="210">';
for (i=0; i<x.length; i++) {
Urls[i]=getTag("location"); Imgs[i]=getTag("image"); //getTag("title"); getTag("creator"); getTag("info");
txt+='<tr><td><table width="295" onclick="play('+i+')" class="playlistlo" onmouseover="this.className = \'playlisthi\';" onmouseout="this.className = \'playlistlo\';"><tr>';
txt+='<td><img src="'+getTag("image")+'" width="90" height="90" border="1" alt="Click to Play"></td><td width="200" valign=top>';
txt+='<p><br> <b>'+getTag("title")+'</b><br>';
txt+=' by: '+getTag("creator")+'<br>';
txt+=' <a href="'+getTag("info")+'" target="_blank">Download it!</a></p>';
txt+='</td></tr></table></td></tr>';
}
txt+="</table>";
document.getElementById(thePlace).innerHTML=txt;
}
It just go One column now..how can I modify to to want I want..
Thanks!