Re: is it possble to inspect the contents of a <noscript> element ?
"rvj" <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.dom |
|---|---|
| Message-ID | <[email protected]> |
AFAIK javascript is enabled (according FF contents tab "enable javascript"
is ticked)
PS. I assume <noscroll/> should be defined inside the <body/> element ?
<html>
<head>
<script>
function noscripts()
{
// get noscript element using documentElement
noscripts=document.documentElement.getElementsByTagName("noscript")[0]
alert(noscripts.tagName) // noscript
// count anchor elements
anchors=noscripts.getElementsByTagName("a")
alert("#"+anchors.length) // 0
}
window.onload=noscripts
</script>
</head>
<body>
<noscript>
<a href="http://www.test.com" >link1</a><br/>
<a href="http://www.test.com" >link2</a><br/>
<a href="http://www.test.com" >link3</a><br/>
</noscript>
</body>
</html>
"Boris Zbarsky" <[email protected]> wrote in message
news:[email protected]...
> rvj wrote:
>> I ve tried use dom methods on the elements of a <noscript/> tag
>>
>> should this work? I keep getting zero elements
>
> If script is disabled, the contents of a <noscript> are basically parsed
> as CDATA.
>
> -Boris