If a user identifies as Opera and loads the NZone page on
it is not possible to use the links "Demos", "Videos", "Screensavers", "Wallpapers" to see lists of download content.
The script detects browsers and sets a few variables – some for detection and some functional ones. One of the functional ones is called "layerRef" and is how the script remembers whether to use document.all (in IE4), document.layers (in Netscape 4) or document.getElementById – the standardised alternative supported by nearly all other modern browsers.
else if (NS6 || NS7 || Mozilla)
eval(layerRef + "("listData").innerHTML = demoDataHTML;");
eval(layerRef + "["listData"].innerHTML = demoDataHTML;");
This is because "layerRef" has been set to document.getElementById but NS6, NS7 and Mozilla are all false when you identify as Opera.
Opera then tries to execute the final line which evaluates as:
document.getElementById["tableTitle"].innerHTML = newTitle;
Since that means they are calling a function with square brackets, the script fails.
Morale: if you mix two different types of sniffing: by browser name and by functionality – you risk getting lost in the messy branches of your script. Clean object detection is way better.