There is a function called wp_script_is( $handle, $list )
. $list
can be one of:
- ‘registered’ — was registered through
wp_register_script()
- ‘queue’ — was enqueued through
wp_enqueue_script()
- ‘done’ — has been printed
- ‘to_do’ — will be printed
Ditto all that for wp_style_is()
.
Related Posts:
- How to dequeue / deregister any theme styles and scripts
- Best spot for wp_register_script() and wp_register_style()
- Register script/style: Is it possible to customize the version query string via plugin?
- How to enqueue JavaScript file that depends on CSS stylesheet
- wp_enqueue doesn’t load dependencies
- Why do WordPress adds the id=”handle-{js|css}” attribute to scripts and stylesheet?
- Where is the right place to register/enqueue scripts & styles
- Load js/css files only on specific admin UI pages
- Hyphens vs. periods in the script slug in wp_register_script?
- Using multiple versions of jQuery while still calling it like WP likes
- How to force that styles are enqueued in the header?
- Where is the right place to register/enqueue scripts & styles
- wp_enqueue_scripts does not work
- Enqueue Scripts / Styles when shortcode is present
- When should I use wp_register_script() with wp_enqueue_script() vs just wp_enqueue_script()?
- How do I dequeue a parent theme’s CSS file?
- How to load css in the footer [duplicate]
- How can I get a list of all enqueued scripts and styles?
- Load CSS/Javascript in frontend conditionally if block is used
- How to properly dequeue scripts and styles in child theme?
- Prevent Version URL Parameter (?ver=X.X.X) on Enqueued Styles & Scripts
- How can I de-register ALL styles all at once? And same with Javascript?
- Cannot deregister a script using wp_deregister_script
- Enqueue custom font file with rel=”preload”
- Removing specific style from wp_head
- Notice that the wp_enqueue_style is not being called correctly!
- Trying to load different syles for 404.php page
- $wp_styles->registered not giving ALL the styles?
- How to use wp_enqueue_style() and wp_enqueue_script() only when needed?
- Preload key requests using wp_enqueue
- Remove a script from a template file using wp_dequeue_script
- Remove specific CSS and JS from the head
- wp_enqueue_script vs. wp_register_script
- Best way to enqueue extremely popular scripts like bootstrap and font awesome
- How to dequeue / deregister parent theme style
- Enqueued scripts and styles loading in WordPress Dashboard as well
- How can I load script and style in specific page in the back-end?
- wp_enqueue_script with dependencies doesn’t work
- How to switch css files according to devices and button click?
- How to control the order of the combination of enqueued styles and scripts – site speed issue
- Help with enqueing scripts in footer after init action
- How to load script-related styles automatically?
- is_page() function doesnt working
- Modernizr check first, then move on to wp_register_script()/wp_enqueue_script
- How to cancel `wp_print_scripts`?
- Deregister scripts on unnecessary pages using remove_action
- Including style.css in Child Theme
- Enqueue Style for a page/pages only
- Why are files enqueued with wp_enqueue_style and wp_enqueue_script 404 Not Found?
- Deregistering a script in WordPress seems impossible
- using conditionals on enqueue styles
- Including files in Child Themes
- wp_enqueue_script Doesn’t Work?
- Exclude external uri for css and js version
- How to enqueu php files with custom variable & conditionals?
- Enqueue never runs
- Change script type and src of plugins in theme
- Adding multiple wp_register_scripts for templates in WordPres?
- Localizing script to pass a value to a javascript function
- How can I properly enqueue tags in WordPress to use with Web Components?
- Enqueuing script is adding extra text for google maps [closed]
- Deregister multiple scripts using a function?
- Load same stylesheet for front end and wp-admin
- Enqueueing Scripts and Styles
- How to remove all enqueued assets from the active theme?
- How to add conditionals for IE browsers between certain versions?
- Should we explicitely enqueue jQuery and our theme’s main stylesheet?
- Modular CSS and JS in Child Themes
- All of my Scripts and Enques are getting file not found
- If a Script has been enqueued but not registered can I still removed it?
- How to use wp_enqueue_script, style when required
- include jquery plugin file not working
- Enqueueing Scripts/Styles mid-page
- how to load css and js based on post template
- How to use wp_register_script / wp_enqueue_script for multiple queries
- I want to set global directory locations for my CSS and JS locations. How?
- How to register script with null value for version?
- javascript file is not enqueing
- Using wp_enqueue_script on scripts that contain PHP
- Enqueueing Scripts and Styles to page template that has html
- FullCalendar in WordPress is not working
- Check for Twitter Bootstrap Loaded
- is there a way to get all queued scripts/styles into a template without `get_header()`?
- How do you load js and style resources from CDN with local fallback using wp_enqueue_scripts?
- Stop a plugins js and css from loading on all pages and show up only where it is called
- Filter enqueued styles and scripts
- WordPress wp_enqueue_style and wp_enqueue_script not working
- Stylesheets and scripts not loading
- Enqueue registered dependencies only when necessary
- Scripts and stylesheets failing to load in Chrome IOS (and only Chrome IOS)
- Enqueue script with version number not working
- How to enqueue a script on a specific URL that contains multiple parts
- i can’t handle any style or Js file on my theme . what is the problem of this file?
- How to get, in WP page’s script, a wp enqueued script (in Functions.php)?
- Should I be enqueueing styles/scripts once and then dequeueing them?
- List all non-admin enqueued files
- Most optimal way of starting fresh, without using other theme or dropping old files?
- wp_enqueue_scripts hangs
- Should I use wp_register_style(), wp_enqueue_style, or both?
- Dequeue/deregister scripts for everybody but the administrator