Benches Apps and software

5

Problem Creating an Image Link within an html s...

apple Verified

Imported from the Apple Support Forums via the Wayback Machine 🔗

Hi,

For some reason I have been unable to link to an image on my Mac by using <img src within an html snippet.

I have uploaded the photo to my server and created a link with <img src "http://www.domain.com/image.jpg" />.

However, when I try linking to the image like this - <img src "Users:Documents:Photos:image.jpg" />, when I click apply on the html snippet all I get is a blue dot with a question mark and I have checked that the image is in my Documents and then Photos folder and it is. When I link to it with the server the photo shows.

Any ideas as to what I am doing wrong?

I would appreciate some help, as I have tried various combinations to link and nothing seems to be working except linking directly from my server and I don't really want to do this at the moment.

Thanks

5 replies

Sign in or join Beachball Help to reply.

  1. 0

    Apple Support Community member

    Imported from the Apple Support Forums via the Wayback Machine 🔗

    [Please teach me HTML|http://www.google.com/search?q=pleaseteach+meHTML]

    [IMG - Inline Image|http://htmlhelp.com/reference/html40/special/img.html]

    [Absolute vs. Relative Paths|http://www.communitymx.com/content/article.cfm?cid=230ad]

    [Relative vs. Absolute URL|http://www.ibdhost.com/help/path>

  2. 0

    Apple Support Community member

    Imported from the Apple Support Forums via the Wayback Machine 🔗

    A few things;

    1) The correct syntax would be src="path"

    2) You need to specify a URL and if you are trying to do this locally it would be in the form of file:///path/folder/document.jpg.... And you would separate directories with a / not a :. Your URL is also missing your computers username.

    To find the URL to a file drag the file from your Finder onto Safari's path bar at the top of a new browser window. Copy and paste that into iWeb. If you move the file, or rename any of it's parent folders, the link will no longer work.

  3. 0

    Apple Support Community member

    Imported from the Apple Support Forums via the Wayback Machine 🔗

    Thanks for that and I did use correct syntax in the html snippet - it was a typo here.

    I did as you suggested and dragged the photo into the Safari browser, after placing the photo on the desktop and it gave me the file name and that showed as file:///Users/My username/Desktop/Image.jpg, so I tried this in my html snippet and did it as so:

    It is still not working for some reason and when I click apply, the photo shows up as a blue square with a question mark in it, although I know the photo is there.

    Why is this? I followed the path, yet when I link to the photo on the server with it works perfectly everytime.

    Thanks

  4. 0

    Apple Support Community member

    Imported from the Apple Support Forums via the Wayback Machine 🔗

    Bonjour,

    It is not possible to see the image in iWeb, but once your iWeb site is published in a folder, the image appears in the browser.
    !http://i62.servimg.com/u/f62/09/02/44/99/iwebsa11.jpg!

  5. 0

    Apple Support Community member

    Imported from the Apple Support Forums via the Wayback Machine 🔗

    Thanks for that and I just discovered that - I published to a folder and there were the photos that I had linked to.

    Makes it difficult to alter the size and position of the images when you can't see them, but I thought that if I linked to the images that I uploaded that I can see on my server/host, then I could set the sizing that way and then set the link to my desktop again and it should then be okay.

    Thanks again.