Hey, welcome to ZBCode, the premier coding forum for ZB. Here you fill find some of the best Invisionfree and Zetaboards Codes on the network! Unfortunately, you're sorta hovering around in guest mode at the moment; why not join in on the fun? Register an account and you can start accessing the wealth of resources we have available here. Enjoy your stay at ZBCode, and remember to tell all your friends about us; the more members, the more codes available. ![]() Interested in joining? Click here. If you are already a member of ZBCode, feel free to login right here: |
| [Completed] [ZB] Javascript Help | |
|---|---|
| Tweet Topic Started: Nov 2 2009, 05:51 PM (244 Views) | |
| Joel | Nov 2 2009, 05:51 PM Post #1 |
![]()
|
Hi ![]() Ok, I'm using some Javascript to allow me to create a hyperlink that when clicked, will change the image above it, however, it doesnt seem to be working. I got the idea from This website (Tip.it). When you click on the Party Hat colour links and the Masks, they change to the associated colour. On my webpage, I have the following:
This works on the website I got the idea from, but doesnt on my webpage. I looked to see if there was any Javascript connecting with this script that I havent got on my webpage but from what I can see, all I need to do is give the image an ID (which I have "photo") and then that ID goes into the script so it points at that image. Any ideas? |
![]() |
|
| Reid | Nov 2 2009, 06:05 PM Post #2 |
![]()
What? The land of the free? Whoever told you that was your enemy.
![]()
|
Go to Firebug -> Console (or in Chrome, right click -> inspect element -> press esc once the DOM has loaded) and type in and hit enter. You'll see what powers the code. ![]() If you don't have firebug, you can find out more about it (and some other useful stuff) in this topic. |
| The Resource Board | |
![]() |
|
| Gorgor | Nov 3 2009, 10:01 AM Post #3 |
|
Hello
![]()
|
Try this:
Then for the links, make the href
Edited by Gorgor, Nov 3 2009, 10:03 AM.
|
![]() |
|
| Joel | Nov 3 2009, 04:44 PM Post #4 |
![]()
|
Wicked That works ![]() Anyway to change the Link back and forth? So for example, when you have the Chat image displaying, the hyperlink below says "Full" to switch to the full avatar image, and then when the Full image displays, the link changes to the "Chat" link. :p If it's more complicated than a simple If Statement, then dont worry about it ![]() Cheers
Edited by Joel, Nov 3 2009, 04:46 PM.
|
![]() |
|
| Gorgor | Nov 3 2009, 04:59 PM Post #5 |
|
Hello
![]()
|
Make the link
|
![]() |
|
| Joel | Nov 4 2009, 05:55 AM Post #6 |
![]()
|
Works a treat! Cheers dude
|
![]() |
|
| Gorgor | Nov 4 2009, 03:20 PM Post #7 |
|
Hello
![]()
|
You're welcome. See? We can read thoughts too. ;) Your request has been completed, and we're moving it to the correct forum. We hope it works for you; if it doesn't, feel free to post another request topic in the requests forum. Just remember: read the rules first! Thanks, The ZBCode Staff |
![]() |
|
| 1 user reading this topic (1 Guest and 0 Anonymous) | |
| « Previous Topic · Completed Requests · Next Topic » |

















That works
2:26 PM Jul 11