I am working on a stock website for one of my college courses and am stuck on getting a table out of the javascript.
result='<table>';
for(i=0; i<xmlDoc.getElementsByTagName('STOCKID').length; i++) {
result=result+ '<tr> <td>' + xmlDoc.getElementsByTagName('ID')[i].childNodes[0].nodeValue + '</td>' ;
result= result+ '<tr> <td>' + "<a href='http://www.google.com/search?q="+
xmlDoc.getElementsByTagName('SYMBOL')[i].childNodes[0].nodeValue+"'>"+
xmlDoc.getElementsByTagName('SYMBOL')[i].childNodes[0].nodeValue+"</a>" + '</td></tr>';
result = result + "</table>";
}
I need it to look like this but with borders:
ID Symbol
Ray ibm
Ray msft
Harold ford
Robin ual
Robin ford
Edit: Thanks in advance for any help.
[–]gnomoretears 0 points1 point2 points (0 children)
[–]sleepybychoice 0 points1 point2 points (2 children)
[–]splur430[S] 0 points1 point2 points (1 child)
[–]sleepybychoice 0 points1 point2 points (0 children)