Forum Moderators: open

Message Too Old, No Replies

HTML & Javascript

         

circuitjump

7:31 pm on Oct 9, 2003 (gmt 0)

10+ Year Member



Hi everyone,

Got a quick question. Is there a way to tell javascript to print and show it's html output?

For example

for (i=0; i<displayPicDirNum; i++) {
mainTableDisplay += '<tr>'
mainTableDisplay += checkTD(picDir[i],displayPicDirNum);
document.write (mainTableDisplay);
mainTableDisplay += '</tr>'

where mainTableDiplay is some <td> tags that it's going to use to add to the table row.

So I want to tell JS to print out a copy of the HTML output.
Like so on the page.

<tr>
<td> stuff</td>
</tr>

Hope I'm making sense.

Thanks

MonkeeSage

8:34 pm on Oct 9, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yes, it relatively easy to dynamically write element values (or even clone exact copies of the whole element, &c), but I'm not sure what you're trying to do exactly. Can you explain where you want to read data from and where you wan to put it? As I understand you you want to read data from? and display it in a table...?

Jordan