Sorry wrong code. Here is the correct line of code…
<div id=”logo”><?php echo ‘<img src=”wp-content/themes/adlibitumensemble_/images/logo.png” width=”400″ height=”159″ />’; ?></div>
Always use full (absolute) urls in WordPress.
<div id="logo"><img src="http://example.com/wp-content/themes/adlibitumensemble_/images/logo.png" width="400" height="159" /></div>
Or even better (in a template file):
<div id="logo"><img src="<?php echo get_stylesheet_directory_uri();?>/images/logo.png" width="400" height="159" /></div>
Andrew Nevins
(@anevins)
WCLDN 2018 Contributor | Volunteer support
Are you missing the forward slash at the start of your image source url?
@ Esmi Theme Diva & Forum Moderator
I am currently building this website on localhost at the moment before I upload it online. it could be the reason why I cant see the logo. Thanks. I will keep in mind to use full urls.
Will try your solution.
@ Andrew
You mean (Check bolded text) in the code
<div id=”logo”><?php echo ‘<img src=”/wp-content/themes/adlibitumensemble_/images/logo.png” width=”400″ height=”159″ />’; ?></div>
You mean the forward slash just after the <img src=”/
Andrew Nevins
(@anevins)
WCLDN 2018 Contributor | Volunteer support
Yes, that is what I mean. You may get a better long-term result with Esmi’s recommended code, “Or even better”.
@ Esmi Theme Diva & Forum Moderator
Gosh – the full title! 😉
Please try one or other of the suggestions I made above. Using relative urls anywhere within WordPress will always produce unpredictable results.
Okay. Thanks Andrew. Will try this and see what goes
Hi Esmi. It worked. Thanks for your help 🙂