• I have ftp’d images to my WordPress test site. In developing a new theme based on K2, I cannot view them when using the <img> tag in the xhtml. In IE the images are displayed as red x’s. In Mozilla Firefox, only the “alt” text displays.
    I have spent hours trying to work through this problem amd cannot find a solution. Is there someone out there who can help PLEASE??

    Thanks,

    Antoine (www.cycletheplanet.com -> currently switching to wordpress from joomla)

Viewing 6 replies - 1 through 6 (of 6 total)
  • The <img> tag has an incorrect src parameter set, apparently. But it’s not clear to me what you did. Did you put the images into posts, or into your theme?

    When I look at your site, I see an image in the upper left, but no broken images. Maybe be a little more specific…

    Your not using the correct path to the images. I like to use this in my themes.
    <img src="<?php bloginfo('template_directory');>/images/image.jpg" alt="image" />
    The /images/ is the folder inside the theme directory that holds the themes. Using this if you decide to release your theme it will work no matter the structure of other’s wordpress.

    Thread Starter cycletheplanet

    (@cycletheplanet)

    Just a quick reply, I can give more tomorrow.

    >> Did you put the images into posts, or into your theme?

    I put the images in my theme like this:
    I am using <img src=”img/imagename”>

    I have also tried with: src=”/theme/themename/img”

    I have also tried with src=”https://web16&#8230;

    All to no avail.

    Any more thoughts?

    Thanks for your help.

    Thread Starter cycletheplanet

    (@cycletheplanet)

    I have added:
    <img src=”<?php bloginfo(‘template_directory’);>/images/image.jpg” alt=”image” />

    This crashes the site, making it go completely blank.
    Only the removal of this line from the source code of the header file resolves the problem.

    Additionally, the theme must be removed and replaced.

    Accessing the image directly such as:

    https://www.site.com/themes/themename/images.gif

    causes an error 404

    Thus, the image also does not load when it is displayed from within the code of the site.

    Does anyone have any ideas why this problem happens??

    Thanks.

    <img src="<?php bloginfo('template_directory');>/images/image.jpg" alt="image" />
    should have called the image if you correctly changed the paths on the code.
    If your getting a 404 error then the image either isn’t there or the permissions are set wrong on the file.

    Hi! I’m having a similar problem.

    My file is definitely there, and wordpress can reach it through the url() function. But I can’t reach it by direct navigation nor through <img src=”” />.

    Therefore, it must be permissions. How do I change the permissions?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Image Viewing Problems’ is closed to new replies.