• I’m trying to build a website using wordpress and semantic.gs but I after opening header.php I’m a bit confused.. the part I’m trying to add is this:

    <link rel="stylesheet" href="css/screen.less" type="text/less" media="screen" />
    <script src="js/less-1.1.3.min.js" type="text/javascript" ></script>
Viewing 1 replies (of 1 total)
  • You need to enqueue the script and style sheet first.

    You can add the following to your functions.php

    add_action( 'wp_enqueue_scripts', 'add_less' );
    
    function add_less()
    {
    	wp_enqueue_script( 'less_min', get_stylesheet_directory_uri()."/js/less-1.1.3.min.js" );
    	wp_enqueue_style( 'screen_less', get_stylesheet_directory_uri()."/css/screen.less" );
    }
Viewing 1 replies (of 1 total)
  • The topic ‘How Do I Put This In header.php?’ is closed to new replies.