The tag has no wiki summary.

learn more… | top users | synonyms

0
votes
1answer
38 views

Split Media Queries in different files!

I woke up this morning with a thought. Is it a good idea to split the different media queries in different files, check the width of the page in functions.php and then with an IF call the "correct" ...
1
vote
0answers
64 views

How do I view registered syles and scripts for enqueue

I know that wp_register_style(), wp_deregister_style() and wp_enqueue_style() are used for css style registration and enqueue management. However, I am interested in viewing ALL registered styles ...
1
vote
1answer
396 views

Load custom css after bootstrap

I have this in functions.php. How can I modify it so that my custom css is loaded after bootsrap.min.css? function register_css() { wp_register_style( 'bootstrap.min', ...
1
vote
1answer
900 views

Why wp_register_style() is important while I'm using a complete wp_enqueue_style()? [duplicate]

Currently I'm working on a theme, and did some styles and scripts enqueue. When enqueued the scripts, I used wp_register_script() first, and then enqueued with wp_enqueue_script() - because I got ...
0
votes
2answers
162 views

Relative path in wp_register_style not working

I have this function: function test_add_my_stylesheet() { wp_register_style( 'test-admin-style', plugins_url('../css/style.css', __FILE__) ); wp_enqueue_style( 'test-admin-style' ); } but ...
0
votes
2answers
135 views

How to dequeue css files?

I have bought a theme, but on a particular page i don't want to use the theme js/css files. The theme registers the files like function add_our_scripts() { global $post; $options = ...
0
votes
1answer
53 views

Style file inclusion

I am trying to include a flexslider.css file with this code: wp_register_style( 'flexslider', get_template_directory_uri() . '/css/flexslider.css' ); if( is_page( 'home' ) ) { wp_enqueue_style( ...
2
votes
1answer
61 views

Naming script handles right way

I was wondering is there any convention or what is the right way for naming handles in wp_register_script() and wp_register_style() functions? For example if I am developing a plugin that uses ...
1
vote
2answers
232 views

Avoid to load default WP styles in login screen

Is there some way to avoid the load of default WordPress styles in login screen to only load my custom stylesheets? Actually I'm using this code: function login_styles() { // Sets the styles if ...
0
votes
1answer
67 views

wp_enqueue doesn't load dependencies

I'm trying to load style.css but rest.css should be included first. I don't understand why reset.css is not included function addMyScript() { wp_register_style('style', ...
0
votes
1answer
864 views

WP deregister, register and enqueue dequeue

a plugin that I bought is loading a few js and css files on all pages, so I wanted to write a new function to deregister the handles, and enqueu them where I wanted. however I am not sure If I have to ...
0
votes
1answer
97 views

Change path/url of admin-bar.min.css

Does anyone know where admin-bar.min.css is registeded/included? Im trying to add a slash in front of admin-bar.min.css, so the admin bar will work correctly on all pages. Im playing arround with a ...
4
votes
1answer
3k views

How to enqueue style before style.css

How do I enqueue a .css file before style.css is loaded? Or make the default style.css dependant on another .css file? I'm trying to load a .css reset, which style.css would overwrite. Here's what I ...
0
votes
1answer
2k views

How do I register/enqueue a custom CSS file?

Good Day. I am using a Wordpress theme and I want to add my own custom CSS. Now I have tried adding my own separate stylesheet after all the other php stylesheet calls in the header.php file. I tried ...
0
votes
1answer
262 views

Register script/style: Is it possible to customize the version query string via plugin?

Expanding on the question in the title: I would like to find a way (via a plugin) to use timestamps for the JS and CSS file version query strings that are output with wp_register_style and ...
-1
votes
1answer
369 views

wp_register_script and wp_register_style when shortcode is used

hi so I used a great tutorial off of http://scribu.net/wordpress/optimal-script-loading.html and I am having trouble loading the scripts when a shortcode called lightbox is used here is my code. I am ...
0
votes
1answer
857 views

Deregister a CSS file that comes with a plugin

WPML plugin comes with its own CSS file. I want to get rid of all the CSS it contains, so I put everything between /* */. However I'll have to do that again when I'll update the plugin. Is there a way ...
0
votes
1answer
632 views

Use conditionals with wp_enqueue_style to attach stylesheet according to post type displayed

I have many custom post types, including some introduced by plugin such as bbPress or WooCommerce. My standard stylesheet is growing large, so I thought to split it into multiple stylesheets ...
5
votes
1answer
1k views

Load js/css files only on specific admin UI pages

How do I adapt this solution to work with my plugin? (Please see the link). I enqueue my css and js script as follows: function my_plugin_init() { wp_enqueue_script('my_plugin_script', ...
0
votes
1answer
91 views

Need some PHP schoolin'! passing var to url and the old options table

So, I've been building a theme options page, one of the purposes of which is to get some style values to pass to my php stylesheet in the url. Here's what I have: /* Get all theme settings */ ...
27
votes
1answer
5k views

Where is the right place to register/enqueue scripts & styles

I am using WordPress 3.1.4 by now. I am confused with where (which hook) do I use: to register and/or enqueue scripts and styles on front- and back-ends? Questions: Which are right hooks to ...
4
votes
1answer
4k views

Why is style.css not being enqueued?

I got a pretty basic theme and just found out my style.css file doesn't get loaded into the <head>. I already searched around but can't find out, why it's not loading. I inspected the global ...
16
votes
3answers
4k views

Check if a script/style was enqueued/registered

Is it possible to test whether a script or a style was registered using wp_register_script/_style or wp_enqueue_script/_style? All functions doesn't return a value and I'm completely clueless. I ...