How to include CSS and JS files in the WordPress plugin.
First, we call a hook for adding scripts.
add_action(
'wp_enqueue_scripts'
,
'Your_function_name'
);
Your_function_name(){
wp_enqueue_style( 'admin/Front', plugins_url( 'Path your css file', __FILE__ ), (F/T)false, Verstion('1.0') );
wp_enqueue_script( 'admin/Front', plugins_url( 'Path your css file', __FILE__ ), (F/T)false, Verstion('1.0') );
}
wp_enqueue_script( 'admin/Front', plugins_url( 'Path your css file', __FILE__ ), (F/T)false, Verstion('1.0') );
Comments
Post a Comment