Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 09-29-2008, 02:55 PM   #1
chilliardGD
UI/UX Developer
 
Join Date: Sep 2008
Posts: 7
Default How To Make a Button link to a website



I have made a navigation bar for my website, but I do not know the coding to make the buttons link to a web page when click upon. Can someone supply me with the link or directions on how to do this? Thank you

Thank you.
chilliardGD is offline   Reply With Quote
Old 09-29-2008, 03:34 PM   #2
CyanBlue
Super Moderator
 
CyanBlue's Avatar
 
Join Date: Jan 2002
Location: Centreville, VA
Posts: 26,666
Default

Howdy and Welcome...

You are looking for a command called getURL() to open up a new link...
ActionScript Code:
getURL("http://www.actionscript.org", "_blank");
__________________
CyanBlue / Jason Je / Macromedia Certified Flash Developer & Designer
http://CyanBlue.FlashVacuum.com
http://www.FlashVacuum.com
http://tutorials.FlashVacuum.com

Do NOT PM, Email or Call me... Your question belongs right in this forum...
CyanBlue is offline   Reply With Quote
Old 09-29-2008, 03:52 PM   #3
chilliardGD
UI/UX Developer
 
Join Date: Sep 2008
Posts: 7
Default

before I add that into the actions panel do I need to put in the mouseFunction code in? I am very new to this by the way. lol
chilliardGD is offline   Reply With Quote
Old 09-29-2008, 08:16 PM   #4
atomic
Banned by AS.org Staff
 
Join Date: Jan 2007
Location: Montréal, Québec
Posts: 14,073
Default

On the main timeline, assuming your navigation bar has the instance name of nav_mc and that the button has the instance name of some_btn...

nav_mc.some_btn.onRelease = function(){
getURL("http://www.actionscript.org", "_blank");
};

Alternately, on the button symbol itself..

on(release){
getURL("http://www.actionscript.org", "_blank");
}
atomic is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

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 Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
button link to keyboard tobycraftse ActionScript 3.0 0 06-04-2008 09:11 PM
button link to keyboard tobycraftse ActionScript 2.0 0 06-04-2008 05:51 AM
Button in Flash that goes to a link within the page mrraulpusso Other Flash General Questions 1 11-03-2005 11:48 AM
when button is clicked, make sure MC is at certain frame before playing next section livingeachday ActionScript 2.0 3 04-27-2004 09:39 AM


All times are GMT. The time now is 09:15 AM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.