Custom themes that won’t work when theme is changed
Custom themes that won’t work when theme is changed
Custom themes that won’t work when theme is changed
I am guessing you are editing a page/post, if yes, go to the right panel, under Features Image, remove it
It seems like the WordPress community really loves this mix of PHP and HTML together, and as you say it often leads to very hard to understand and maintain code. It is a common programming pattern to separate out ‘logic’ and ‘presentation’. Logic here is PHP code which makes decisions, presentation is HTML. I strongly … Read more
With the code that you’ve added to your question, you’re adding the HTML ‘checked’ attribute twice, which is probably why things are getting confused. You have it hard-coded as checked=”checked”, but then checked( 1, get_option( ‘theme_custom_option’ ), false ) will write another checked attribute corresponding to the actual value of the option. You should be … Read more
I would recommend changing it to this: <div class=”home-header” style=”background-image:url(‘<?php echo get_theme_mod( ‘home-header-img’ ); ?>’)”> and adding this to style.css or an other stylesheet: .home-header { height: 500px; width: 100%; display: flex; justify-content: center; align-items: center; background-repeat: no-repeat; } In general, inline styles are not allowed, but Themeforest makes an exception for background-images. So by … Read more
Yes, it’s fine to do that. WordPress doesn’t care if the loop or any of the other content-related PHP in the theme file is there or runs, but you should leave get_header() and get_footer()
Next and previous post link shows error in first and last post
Sidebar not displaying (theme development)
3 Level Menu Navigation (3rd Level not displaying)
Customizer API Multi Sections in single Panel