View Full Version : link button to URL - google style!
meloMO
08-01-2009, 02:34 AM
hey, google tells an advertiser to use the following code:
on (release) {
if (clickTAG.substr(0,5) == "http:") {
getURL(clickTAG, "_blank");
}
}
http://adwords.google.com/support/bin/answer.py?hl=en&answer=26938
this way it gives me a compiling error. so i rewrote at little bit. no worki worki anyway! well, just have a look yourself.
lol, btw, while we're on it. how can i make the sound to continue playing when you're off the button with the mouse, while it wont play multiple times when you move over it again?
meloMO
08-02-2009, 06:08 PM
i rewrote the code to this, but it's not working:
invisible_btn.onRelease = function(){
if (clickTAG.substr(0,5) == "http://www.google.com") {
getURL(clickTAG, "_blank");
};
};
Aberrant
08-03-2009, 12:26 AM
Hello meloMO (again).
lol, btw, while we're on it. how can i make the sound to continue playing when you're off the button with the mouse, while it wont play multiple times when you move over it again?
I will look at your sample upload and see what I can do for you.
Just to confirm; you want the background sound to continue playing unless the button that turns off the sound is clicked?
Aberrant
08-03-2009, 12:51 AM
meloMO
Firstly, if you want the sound to still play out, then simply remove the following code from the Script:
invisible_btn.onRollOut = function(){
snd1.stop();
};
If you want the button to open up a new page if clicked, then add this code in the Action of the button.
on (release){
getURL("http://www.actionscript.org/", "_blank")
}
Though this still works, the experts most likely have a far cleaner approach for you.
Cheers.
meloMO
08-03-2009, 11:43 PM
hey, thanks for your reply. when i just remove that stop part, the sound will play multiple times at once when you go over the button again and again. you see? is there any easy way to solve this?
and well, the problem about the linking part is that google tells me to do it this way:
on (release) {
if (clickTAG.substr(0,5) == "http:") {
getURL(clickTAG, "_blank");
}
}
it's not working though :(
meloMO
08-06-2009, 05:09 PM
whats your problem, dasli?
|
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.