Find out how to add hyperlinks to your Flash project.
So you want to know how to add a hyperlink to your Flash project. Hyperlinks are incredibly common among the web community, and it's possible to use them within Flash, with only a few lines of Actionscript. So, to begin, open Flash. Draw yourself a button or some text. Once you've done that, convert it to a symbol by right clicking it and selecting "Convert To Symbol...". Make sure you select Button from the behaviour list.
The code that we will add later on can only be applied to a button, as we want people to be able to click it, to take them to your site.
Once you've done this, double click on your button with the selection tool and you will go to button editing stage. There are four button stages; Up, Over, Down & Hit. Add a keyframe to each of the four stages. You don't need to make changes to your button throughout these stages if you don't want.
Once you have done this, go back to Scene 1 (your main stage). Your button will still only be on one keyframe. Click on your button with the selection tool. Open the Actions panel by pressing F9. Enter the following code:
on(release){ getURL("http://www.YourSite.com"); }
Now test your project by pressing Control + Enter. You should be able to click the button, which will take you to your website. The result should be something like this. As mentioned previously, you can also add an email link. This simply requires a small addition to the code:
on(release){ getURL("mailto:
"); }
Which would result in this. If you have had trouble following this tutorial, tell us about is on the forum. Likewise, if you have enjoyed this tutorial.