Vlaad
03-30-2003, 11:35 AM
Greetings, forumers,
I've written a page in ASP which queries a db for results (blah, blah, blah), and the results are outputted to the page as they are retrieved.
However, the crux of the problem is that I want to display a 'quicklink' (with just the name of the article and a supplier logo) in the table column that's rendered before the results are retrieved.
I've written the following code, which works fantastically well in Mozilla / Phoenix, but IE rejects it.
<script language="Javascript">
var link = document.createElement('a');
var span = document.createElement('span');
var txt = "EPSON GPS Receiver Module S4E398600010000";
var image = document.createElement('img');
var tr = document.createElement('tr');
var td = document.createElement('td');
link.setAttribute('href','#1');
span.setAttribute('class','editorialQuickLinkTitle');
link.innerHTML = txt;
span.appendChild(link);
image.setAttribute('src','/Images/Logos/Miniatures/epson.png');
image.setAttribute('border','0');
image.setAttribute('vspace','5');
image.setAttribute('hspace','5');
td.setAttribute('class','block');
td.appendChild(span);
td.appendChild(document.createElement('br'));
td.appendChild(image);
tr.appendChild(td);
document.getElementById('querySummary').appendChild(tr);
</script>
Anyone have any thoughts? I'd be happy to leave it as a Mozilla-only thing, but unfortunately most of the users of the site are IE lovers, and I would like to integrate the code into other portions of the site where it will be far more visible.
Thanks for your thoughts (in advance :thumbsup: )
I've written a page in ASP which queries a db for results (blah, blah, blah), and the results are outputted to the page as they are retrieved.
However, the crux of the problem is that I want to display a 'quicklink' (with just the name of the article and a supplier logo) in the table column that's rendered before the results are retrieved.
I've written the following code, which works fantastically well in Mozilla / Phoenix, but IE rejects it.
<script language="Javascript">
var link = document.createElement('a');
var span = document.createElement('span');
var txt = "EPSON GPS Receiver Module S4E398600010000";
var image = document.createElement('img');
var tr = document.createElement('tr');
var td = document.createElement('td');
link.setAttribute('href','#1');
span.setAttribute('class','editorialQuickLinkTitle');
link.innerHTML = txt;
span.appendChild(link);
image.setAttribute('src','/Images/Logos/Miniatures/epson.png');
image.setAttribute('border','0');
image.setAttribute('vspace','5');
image.setAttribute('hspace','5');
td.setAttribute('class','block');
td.appendChild(span);
td.appendChild(document.createElement('br'));
td.appendChild(image);
tr.appendChild(td);
document.getElementById('querySummary').appendChild(tr);
</script>
Anyone have any thoughts? I'd be happy to leave it as a Mozilla-only thing, but unfortunately most of the users of the site are IE lovers, and I would like to integrate the code into other portions of the site where it will be far more visible.
Thanks for your thoughts (in advance :thumbsup: )