WordPress.org

Ready to get started?Download WordPress

Forums

AssetsMinify
[resolved] install on windows 7 not working (2 posts)

  1. kojit9
    Member
    Posted 10 months ago #

    I'm using Windows 7 / WP 3.6 / DesktopServer - In my AssetsMinify configuration in admin section I have:

    Compass compiler's path: c:\Ruby200x64\bin\compass

    In my header.php page I added:

    <?php

    wp_enqueue_style( 'screen', get_template_directory_uri() . '/sass/screen.scss' );

    ?>
    <?php wp_head(); ?>

    It adds screen.scss to my wordpress page - but it does not compile the "/sass/screen.scss" file.

    There are no error messages - Please help

    http://wordpress.org/plugins/assetsminify/

  2. Alessandro Carbone
    Member
    Plugin Author

    Posted 10 months ago #

    Your error is to include directly wp_enqueue_style inside the header.php.
    wp_enqueue_style must be called within a function called from the hook "wp_enqueue_scripts" accordingly to WordPress documentation: http://codex.wordpress.org/Function_Reference/wp_enqueue_style#Using_a_Hook

    Change the code this way and it will work.
    Let me know.

Reply

You must log in to post.

About this Plugin

About this Topic