[theme-reviewers] Embedding inline JavaScript in <head>?

Chip Bennett chip at chipbennett.net
Tue Oct 16 17:08:22 UTC 2012

Is there any particular reason that such a script can't be enqueued like
most other scripts, that would warrant such an exception?


On Tue, Oct 16, 2012 at 12:02 PM, WPForever Team <hi at wpforever.com> wrote:

>  This is my first post here, I hope I'm doing it correctly.
> I want to add a "no-js" class to <html>, and then remove it immediately
> (and add "js") if the browser supports JavaScript. For this, I want to add
> the following as the first thing after <head>
>     <script>(function(h){h.className = h.className.replace('no-js',
> 'js')})(document.documentElement)</script>
> >From what I could understand from the Theme Review page in the Codex,
> this isn't allowed.
> Can this be an exception?
> _______________________________________________
> theme-reviewers mailing list
> theme-reviewers at lists.wordpress.org
> http://lists.wordpress.org/mailman/listinfo/theme-reviewers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.wordpress.org/pipermail/theme-reviewers/attachments/20121016/662e1498/attachment.htm>

More information about the theme-reviewers mailing list