CSS Wordpress wp_enqueue_style()
`<?php wp_head(); ?>`
, wp_head(). .
, wp_head(); header.php.
functions.php , index.php. functions.php , wp_register_script, wp_enqueue_style.
, Bootstrap.
`<?php
function add_stylesheet() {
wp_register_style('bootstrap.min',get_template_directory_uri() .
'/css/bootstrap.min.css');
wp_enqueue_style( 'bootstrap.min' );
}
add_action( 'wp_enqueue_scripts', 'add_stylesheet' );
?>`
, ?
add_stylesheet() - , .
WordPress wp_register_style. 5
`$handle, $src, $deps, $ver, and $in_footer`
After registering our style, we can call it using the WordPress function wp_enqueue_style. That is, this method may seem complicated at first, but it is the preferred method of invoking style sheets in WordPress.
source
share