[theme-reviewers] html5.js enqueuing

Philip M. Hofer (Frumph) philip at frumph.net
Wed Jun 12 15:33:20 UTC 2013


	echo '<!--[if lt IE 9]>';
	    echo '<![endif]—>'; The above code in your functions.php will not work right.

There’s no guarantee that the enqueing of this script will appear in the position between the echo’s. 

However, you could do something like:

global $is_IE;
if ( $is_IE ) {
    wp_enqueue_script('ie7style', get_template_directory_uri() . '/js/html5.js');}which then you wouldn’t need directives, but it would hit all IE browsers, if that’s fine with you – and this would be the most appropriate way of handling this situation



From: D5 Creation Support 
Sent: Wednesday, June 12, 2013 8:21 AM
To: theme-reviewers at lists.wordpress.org 
Subject: [theme-reviewers] html5.js enqueuing

Dear Reviewers,

Greetings from D5 Creation!

Please find the following Tickets first: 

http://themes.trac.wordpress.org/ticket/12433

http://themes.trac.wordpress.org/ticket/10354

One of our Themes named Easy was not approved today. One of the 2 required issues is enqueuing the html5.js from functions.php via callback function. The reviewer advised to do hard coding the html5.js from header.php as Twenty Twelve does.

Our another Theme Design was not approved due to hard coding the html5.js from header.php rather than enqueuing. 

Which reviewer is correct? JavaScripts are required to enqueu via callback function as per the guideline. 


Thanks

D5 Creation Team 


--------------------------------------------------------------------------------
_______________________________________________
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/20130612/62caeb1c/attachment.html>


More information about the theme-reviewers mailing list