Two images seem to have the same link — please help.

September 11th, 2008 · No Comments

Hi Janine -

I’m hoping you can help. I’ve been searching and searching for an answer to a problem I’ve run across, to no avail.

I am creating my website in Dreamweaver CS3 and I’ve run into a situation I can’t resolve. I have two images on a page that are supposed to link to different pages on the site. They seem to have become connected to each other somehow because when I change the link for one of the images, the link for the other image changes as well. I’m not using any sitewide link change options, just doing it manually.

Any help you can give would be greatly appreciated.

Thanks and I love your site!

Rachel

Hi Rachel,

I can suggest a couple of solutions to your problem. The simplest is to add some space or a return between the images. Remove the link and then reset each link separately. Once you have some space between them, Dreamweaver should recognize that they are separate links.

If that doesn’t work, you may need to fix the links manually in the code. Here’s a quick guide to how that would work:

The HTML for a link begins with the tag <a href=”link.html”> and then has </a> at the end. Image tags use <img src=”image.jpg”>. You may need to cut and paste the </a> tag so it appears between the two tags for the images instead of surrounding both of them to create one link.

Here’s an example of how yours might look now:

<a href=”link.html><img src=”image1.jpg”><img src=”image2.jpg”></a>

You would need to cut and paste the </a> so the images are separated like this:

<a href=”link.html><img src=”image1.jpg”></a><img src=”image2.jpg”>

Of course, there may be other code that makes your pages a little more complex, but this is essentially what the code probably looks like and how you would fix it.

I hope that helps and I wish you all the best,
Janine

Hi Janine -

Thank you SO much for your speedy response. I took the plunge and looked at the actual code and was able to fix it. For some reason there was no <a href = linkimg.html> before the second image I was trying to create a link for. So I guess both images were referencing the same link.

I feel much more confident about working with the actual code now instead of doing it all visually, thanks to your clear instructions!

Thanks again.
Rachel

Still want more? Visit the Dreamweaver Help Center at www.DigitalFamily.com/dreamweaver to find Dreamweaver tips, tricks, and tutorials.

Tags: Dreamweaver 8 · Dreamweaver CS3 · Dreamweaver MX · Dreamweaver MX 2004 · expression web · Links · Web graphics

0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

You must log in to post a comment.