Image path ?
-
Every time I start one of these projects again after some time away I run into this issue and it’s absolutely maddning.
I’m working on a new wordpress site and I’m developing it on my laptop. So here’s the setup…
I’m doing this on my laptop i.e. Windows 8, Apache, MySQL, PHP.Site (landing / index page) is located htdocs/MyWebSite/wp-Content/themes/Socates4/index.php
The image I’m trying to put on a page or in a post is located here…
htdocs/MyWebSite/wp-Content/themes/Socates4/imagesI’m trying to use a relative path and having “0” success.
I’ve tried every variation I can think of …
<img src=”images/myImage.png” alt=”My Picture” height=”150″ width=”960″><img src=”/images/myImage.png” alt=”My Picture” height=”150″ width=”960″>
<img src=”//images/myImage.png” alt=”My Picture” height=”150″ width=”960″>I’m sure it’s got to be the path syntax. I have tried every variation on the path syntax I can think of…
image/myImage.png
/image/myImage.png
//image/myImage.png
./image/myImage.png
/socrates4/image/myImage.png
/etc. etc…I can give my browser this…
https://localhost/MyWebsite/wp-content/themes/socrates4/images/MyImage.png
and it puts my image into the browser at its actual size 150 X 960. Just as you would expect. Works fine. It finds and displays the image.
So what am I missing here? Why can’t I get the image to display from a post ?
Why can’t I use html <img> tag syntax to display this image?
- The topic ‘Image path ?’ is closed to new replies.