[How To] Load Theme Style Dynamically And Hide Paths

Because the CSS and JS are called statically for a good loading speed of the entire website, Hide My WP Ghost will not change the paths and remove the comments within the website theme style.

If you really want to change the paths and remove the theme comments, you can set Hide My WP Ghost to load it dynamically.

To do this, follow these steps:

  1. Add this line in wp-config.php file after the line with define(‘WP_DEBUG’ ….
    define( 'HMW_DYNAMIC_THEME_STYLE', 1 );
  2. Rename the Theme style name in Hide My WP Ghost> Permalinks > Custom Theme Style Name. Use a name ending in .css (e.g. design.css)
  3. Save the setting and check the website with a different browser or in incognito mode to make sure the style is loaded correctly.
1 Comment
  • hi
    After installing the Hide My WP plugin, JS and CSS will not load properly on my site.
    I did the following and it didn’t work !!

    1- Add this line in wp-config.php …
    define( ‘HMW_DYNAMIC_THEME_STYLE’, 1 );

    2- Use a name ending in .css (e.g. design.css)

    3- In .htaccess :
    If you see 2 similar blocks like above, please remove one of them because this is the main issue in the last versions of WordPress.org

    4 – disable all plugins
    5- change theme
    *** When the plugin is disabled, everything will be fine and back to normal.
    Please Help me.

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.