Tag Info

New answers tagged


Jetpack doesn't really sanitize CSS, it just cleans it up, which has the side-effect of removing some vulnerabilities, but not all. An attacker can still use @import to import unsanitized CSS; expression() to introduce XSS to older IE browsers; @charset to trick the browser into interpreting the CSS as HTML, opening up XSS opportunities; set URLs with ...


Enqueueing styles within a function as you have done is the standard best practice for WordPress, whether you are building a theme or creating a child theme. And as mentioned, you can enqueue both styles and scripts from within one function, http://marker.to/65CMY3.


You could do it like this: function theme_styles(){ /* * This if() statement is unnecessary, as wp_enqueue_scripts * doesn't fire on the admin pages. * if( is_admin() ) { * return; * } */ wp_enqueue_style( 'theme-styles', get_template_directory_uri() . '/css/all.css', array(), false, ...

Top 50 recent answers are included