I made an HTML file with a few divs and named anchors to supply good fallback behavior if JS was turned off. E.g.:
Code: Select all
<a name="topic1"></a><div id="topic1">...
As usual, this works fine in Firefox, but there was no content displayed in any IE version.
The problem is that IE returns the <a> element instead of the <div> for the document.getElementById("topic1") call made by hs code to get the content to display.
There are 2 ways to get around this:
1. The simplest is to put the named anchor after the div in the file to read:
Code: Select all
<div id="topic1"><a name="topic1"></a>...
Code: Select all
<a href ="myfile.html#_topic1"
onclick="return hs.htmlExpand(this,
{ contentId: 'topic1',
src: 'myfile.html#topic1',
objectType: 'ajax', ...
} )">Click Me</a>
Code: Select all
<a name="_topic1"><div id="topic1"></a>
in myfile.html