wp_print_scripts

SummerySummery

Prints scripts in document head that are in the $handles queue.

Syntax

wp_print_scripts( string|bool|array $handles = false )

DescriptionDescription

Called by admin-header.php and ‘wp_head’ hook. Since it is called by wp_head on every page load, the function does not instantiate the WP_Scripts object unless script names are explicitly passed. Makes use of already-instantiated $wp_scripts global if present. Use provided ‘wp_print_scripts’ hook to register/enqueue new scripts.

ParametersParameters

$handles

(string|bool|array) (Optional) Scripts to be printed. Default 'false'.

Default value: false

ReturnReturn

(string[]) On success, an array of handles of processed WP_Dependencies items; otherwise, an empty array.

SourceSource

File: wp-includes/functions.wp-scripts.php


			

ChangelogChangelog

Changelog
Version Description
2.1.0 Introduced.

See alsoSee also

Scroll to Top