• Resolved brendanu

    (@brendanu)


    Hi, I’ve setup SASS to CSS compiler successfully on my local environment, but when I try and install on production it’s not working. The site is hosted on WordPress.com, so it’s a pretty vanilla install.

    Message from WordPress.com logs:

    PHP Warning: Attempt to read property "id" on null in /srv/htdocs/wp-content/plugins/sass-to-css-compiler/admin/class-sass-to-css-compiler-admin.php on line 333
Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Sajjad Hossain Sagor

    (@sajjad67)

    Hi, Will look into this ASAP and get back to you soon. Stay with us.

    Thread Starter brendanu

    (@brendanu)

    Many thanks, we’re attempting to move from “SCSS-Library”, given its security problems, to your plugin.

    Plugin Author Sajjad Hossain Sagor

    (@sajjad67)

    A New version is published v2.0.6 which resolves the issue you are getting. Hopefully it should be resolved once you upgrade to the latest version. If any issue please let us know.

    Thread Starter brendanu

    (@brendanu)

    Hi Sajjad, unfortunately there was no difference…except I’m not seeing the log error anymore. No errors logged for the plugin now though πŸ™

    Strangely looking at your repo I only see that the readme.txt was updated in the latest release – am I reading that correctly.

    Plugin Author Sajjad Hossain Sagor

    (@sajjad67)

    You are not seeing correct… there are few more changes added to the plugin. So your problem should be resolved now!! It should not give any error now. let me know if it is.

    Thread Starter brendanu

    (@brendanu)

    Sorry if my last message was misunderstood. I installed v2.0.6, but there was no change – the SCSS file configured in the settings still isn’t being processed. My local version continues to work however.

    With the updated version, I’m no longer seeing an error in the WordPress.com hosting logs for PHP, just the plugin is still not working as expected.

    Note this is how I’m setting the enqueued styles:

    // Set stylesheets
    wp_register_style('googlefonts', 'https://fonts.googleapis.com/css?family=Open+Sans:ital,wght@0,300;0,600;1,300;1,600', array(), 'v1.0.0');
    wp_register_style('normalize', get_template_directory_uri() . '/assets/css/normalize.min.css', array(), 'v8.0.0');
    wp_register_style('main', get_template_directory_uri() . '/assets/css/src/main.scss', array('normalize'), '1.0');

    // Enqueue the stype
    wp_enqueue_style('googlefonts');
    wp_enqueue_style('normalize');
    wp_enqueue_style('main');
    Plugin Author Sajjad Hossain Sagor

    (@sajjad67)

    ok, have you added the main.scss in the plugin settings? It must be explicitly set in the settings include fields.

    Thread Starter brendanu

    (@brendanu)

    Hi Sajjad, yes I have. Matched the same settings I have running locally where the plugin is working with exactly the same setup – obviously with different hosting (MAMP Pro locally, WordPress.com in production).

    Plugin Author Sajjad Hossain Sagor

    (@sajjad67)

    Can you please share some more screenshots of the settings page… and check the directory if being converted at all… or it’s a enqueue issue. Without that it’s not possible to help you in any way, as it is working for self hosted wp version and other places.

    Thread Starter brendanu

    (@brendanu)

    Hi Sajjad

    I changed the enqueue setup to direct wp_enqueue_style instead of wp_register_style then wp_enqueue_style but still having problem.

    // Enqueue the styles directly
    wp_enqueue_style('googlefonts', 'https://fonts.googleapis.com/css?family=Open+Sans:ital,wght@0,300;0,600;1,300;1,600', array(), 'v1.0.0');
    wp_enqueue_style('normalize', get_template_directory_uri() . '/assets/css/normalize.min.css', array(), 'v8.0.0');
    wp_enqueue_style('main', get_template_directory_uri() . '/assets/css/src/main.scss', array('normalize'), '1.0');

    Here’s the settings:

    Still no errors showing up in logs, and the old SCSS-Library plugin still works.

    Perplexing.

Viewing 10 replies - 1 through 10 (of 10 total)

You must be logged in to reply to this topic.