• Hello. The file wp-mcm-styles.css is loaded on every page request, even when we don’t use the shortcode or use WP MCM in our posts in another way.

            public function add_frontend_styles()
            {
                $this->debugMP( 'msg', __FUNCTION__ . ' started.' );
                wp_enqueue_style(
                    'wp-mcm-styles',
                    WP_MCM_PLUGIN_URL . '/css/wp-mcm-styles.css',
                    array(),
                    WP_MCM_VERSION_NUM . '.1'
                );
            }
     
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author DeBAAT

    (@debaat)

    Hai Jean Paul.

    Sorry I didn’t reply any sooner. Was working on V2.1.0.

    Unfortunately, I cannot determine exactly when to load the css or when not.

    I could introduce a switch to let you determine whether to load the front-end code or not. This would however become only available in the Premium version.

    Please let me know whether you are interested.

    Thanks for the feedback.

    Thread Starter JeanPaulH

    (@djr)

    While I think the plugin is really useful, I don’t have any use for the premium version right now. I’ll find another way to dequeue the styles. Thanks for the answer.

    Plugin Author DeBAAT

    (@debaat)

    Ok, I understand. I’ll close the issue then. Thanks again.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Plugin CSS unnecessary loaded on front-end site’ is closed to new replies.