Home › Forums › WordPress Plugins › Hide My WP › I still see my theme name from inspect element
- This topic has 10 replies, 2 voices, and was last updated 10 years, 2 months ago by
spatdesign.
-
AuthorPosts
-
August 1, 2015 at 3:39 pm #3920
Hello.
The plugin works great for sites like “what wp theme is that” or “wp theme detector”, but with “inspect element” of Chrome I still see the path in a compact form (without wp-content/themes/) but with the real name of my theme.
e.g. http://www.mysite.com/myrealtheme/style.css
How can I fix this? Maybe I don’t have configured properly the settings.
Thanks for your assistance
RegardsAugust 2, 2015 at 5:06 am #3933Hi, can you please let us know your website URL and the page source line number where we can see the theme name?
August 2, 2015 at 12:48 pm #3938This reply has been marked as private.August 2, 2015 at 5:04 pm #3944It is because the name “peak” is hard-coded in child theme’s css file http://www.claudiocaglioti.com/template/sd_main.css
We recommend you to change the theme folder names to something like “claudiocaglioti” and “claudiocaglioti-child”, and make changes to child theme’s css accordingly.
August 2, 2015 at 9:39 pm #3946This reply has been marked as private.August 3, 2015 at 4:23 am #3948It’s because the parent theme name is hard-coded in child theme css. If you do not want to rename theme directories then you can do the following:
– remove the following line from child theme’s css file:
@import url(“../peak/style.css”);
– add following code in child theme’s function.php
add_action( ‘wp_enqueue_scripts’, ‘enqueue_parent_style’ );
function enqueue_parent_style() {
wp_enqueue_style( ‘parent-theme-css’, get_template_directory_uri() . ‘/style.css’ );
}August 3, 2015 at 3:52 pm #3958This reply has been marked as private.August 3, 2015 at 4:16 pm #3962This reply has been marked as private.August 3, 2015 at 4:17 pm #3963That should work! Might be you have missed something.
And regarding the scrambled website after you reverted back, it seems like you missed to add back following line in your child theme’s css file:
@import url(“../peak/style.css”);August 3, 2015 at 4:21 pm #3964Yes, it’s because of hardcoded theme name in css file. Yes, it’s preferred to use the method via function.php rather than via css, and most of the good themes use this function method.
August 3, 2015 at 4:23 pm #3965This reply has been marked as private. -
AuthorPosts
You must be logged in to reply to this topic.

