logo-dw

Go Back   Dreamweaver Club Forums > Dreamweaver forums > Dreamweaver General
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 05-03-2006, 01:56 AM   #1
becky gelke
 
Join Date: Oct 2005
Location: Australia
Posts: 94
Default Problem adding behaviour to a pic

I want to add a behaviour to several thumbnails on a site I am building. I want to be able to click the thumbnail then get a bigger picture of the same pic to open in a new window, with a size I can specify. I have tried to do this by adding a behaviour, then selecting the 'open browser window' option, flillng in all the details, size url etc. but then nothing happens, Am I forgetting to do something? Is there perhaps a small piece of code I can attach to each thumbnail to get them to perform this action for me.
__________________
Thanks Bec x
becky gelke is offline   Reply With Quote
Old 05-03-2006, 05:27 AM   #2
becky gelke
 
Join Date: Oct 2005
Location: Australia
Posts: 94
Default

I think I have sorted it out now, I was using DW4 tried it in MX and it worked fine. It was simply a matter of changing the html from "onload" to "onclick" if anyone is having the same prob. I presume I have done it right??
__________________
Thanks Bec x
becky gelke is offline   Reply With Quote
Old 05-03-2006, 06:11 AM   #3
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

Yes, you got it
domedia is offline   Reply With Quote
Old 05-03-2006, 06:32 AM   #4
becky gelke
 
Join Date: Oct 2005
Location: Australia
Posts: 94
Default

Thanks for that, but I dont quite have it unfortunately. I am adapting a template, when I select the pics in question they already have the # attributed to them, then when I add the behaviour it all works OK, the prob is it also has the effect of flying to the top of the page also. I have added the offending line below. I still want the pics to be hyperlinks (or turn into a hand when moused over, but dont particularly want to go back to the top of the page each time...any ideas??

[img]images/w23.jpg[/img]
__________________
Thanks Bec x
becky gelke is offline   Reply With Quote
Old 05-03-2006, 07:01 AM   #5
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

It's flying to the top of the page because your browser is looking for your link ("#").
If you can I would put the link to large.html as your link, move the onclick function call to your anchor tag, and add a return(false) to have javascript disable the anchor link:
domedia is offline   Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:04 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com