Answers for "register style wordpress"

0

register style wordpress

/**
 * Registers a stylesheet.
 */
function wpdocs_register_plugin_styles() {
    wp_register_style( 'my-plugin', plugins_url( 'my-plugin/css/plugin.css' ) );
    wp_enqueue_style( 'my-plugin' );
}
// Register style sheet.
add_action( 'wp_enqueue_scripts', 'wpdocs_register_plugin_styles' );
Posted by: Guest on June-30-2021
0

register style wordpress

wp_register_style( string $handle, string|bool $src, string[] $deps = array(), string|bool|null $ver = false, string $media = 'all' )
Posted by: Guest on June-30-2021
0

register style wordpress

function wp_register_style( $handle, $src, $deps = array(), $ver = false, $media = 'all' ) {
    _wp_scripts_maybe_doing_it_wrong( __FUNCTION__, $handle );
 
    return wp_styles()->add( $handle, $src, $deps, $ver, $media );
}
Posted by: Guest on June-30-2021

Browse Popular Code Answers by Language