View Full Version : behavior - change text with picture

12-19-2010, 06:05 AM
On this page (http://www.newlifeadoptions.org/), I have the right-hand side pictures connected to the main left picture with a behavior, so that when you click on the small thumbnail picture on the right the appropriate larger picture on the left appears.

Is there a way to make the text in the middle change when the larger picture changes as well? Maybe another behavior? Can you have one action (a click on a small thumbnail) affect two areas (the larger picture plus the text)? Each text group will need to have its own link to a specific url.

12-19-2010, 09:08 AM
Yes. All you're doing on the images, with javascript, is changing the src attribute of the large image. In a similar way you can change the content of your <p> tag (the innerHTML). Have a look here (http://www.tizag.com/javascriptT/javascript-innerHTML.php) for an introduction.

12-30-2010, 08:51 PM
I'm not sure I understand the tutorial you linked to. Can you either explain it more or is there another easier way to do it?

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum