ActionScript 1/2 :: Getting Some Movieclips To Link To Different URLs On Release?
May 14, 2011
Hey. I am having problems getting some movieclips to link to different URLs on release. I am able to get them to animate, and I am able to get them to link to an html page seperately, but I can't get both functionalities to work at the same time (animate and geturl) and it is driving me crazy!! I've tried putting the actionscript in the instance object, in the action layer, and other things and nothing seems to work!?
I've been trying to fix a problem I'm having in flash, but have no idea where to go from here. I am trying to link multiple images to different urls.[code]I need to make each bigImage file link to a different url.
I've got a flash file loaded on more than 150 sites. The button in the file currently goes to a single URL, but we are developing individual URLs for the link for each site. How can I do this in one flash file? I don't want to create 150 flash files with different links. Can I variables or something?
I just made a flash news scroller where the news headlines are dynamic text and have different urls provided in the link section. But when I click on any of them, they all go to the first link only.
I am new to the community, I doing a free website for internship purposes, long story i cannot get my buttons to link in flash site, i have tried many different codes and none had worked, i am a newbie and i need some guidance in the right direction. I have three links Link1, Link 3, and Link 4 The current code I am using is import flash.net.
I just made a flash news scroller where the news headlines are dynamic text and have different urls provided in the link section. But when I click on any of them, they all go to the first link only.
I�m trying to get my horizontal scrollbar gallery images to link to different url�s, but having some trouble getting more than one url to open, they all link to the same site.
So, I have tons o' buttons that each need to link to unique URLs, and I'd like to minimize coding as much as possible. The code below works, but I will have to do this about 50 times.Can I associate the URLs with the instance names of the buttons and then reuse the same function?In the event you didn't already guess, I'm a newbie to AS3
cap_mc.CapTeam_btn.addEventListener(MouseEvent.CLICK, capPage); function capPage (evtObj:MouseEvent) { trace("clicked") var url:String = "http://www.mydomain.com"; var request:URLRequest = new URLRequest(url);
The app is basically an animated character that sits on screen and moves around doing stupid little animations. Each animation (Talking, Dancing, Jumping, etc) is an individual Movie Clip made up of around 50 or so PNGs in sequence. I'm using CS3 to create the clips, and exported them as SWCs for use in Flex. When I addChild() the MovieClip to stage, memory usage increases, which makes sense. However when I use removeChild() on the same clip, and then add another clip, memory increases, and this goes on with every new clip... essentially leaving 10 clips in memory even if they aren't being played.
Now, first thing you are going to think is I've got a reference to the clip somewhere and it's not garbage collecting. Well, I'm using weak listeners everywhere, and I'm pretty sure I've killed every reference by NULLing out the objects. I understand Garbage Collection doesn't happen right away... but it never seems to happen. As a test, I wrote a really bare-bones app to attach and remove a clip to see if the memory ever frees. I've left the app running for a half hour after removing the clip from stage, and memory usage stays the same:
Underlined Text On (rollOver) Is there an action script to do on (rollover) underline text? It would be on a button that would also, on (release) gotoAndPlay a frame. I know you can have a movie with AS like this:
[Code]....
But when I add the on (release) to the movie it doesnt advance the timeline on (release). And when I change the file to a button instead of a movie clip it doesnt do the underline on (rollOver).
I'm working on a small application that uses some throw physics to fling items around the stage. Everything is working as it should, apart from when I test it on my touch screen, the throw physics don't work. I've tried all sorts of things, in in those tests noticed that AS2 release and release outside do work on the screen perfectly, whereas mouse up and mouse out do not!
So, is there a way to emulate the AS2 mouse events in AS3, as I have to stick with AS3 this time.
I am trying to programmatically queue MovieClips on the scene to play one after the other. I have tried onEnterFrame with Event.ENTER_FRAME that gotoAndStop() to next fram each time, but this does not show the MovieClip playing somewhy.Is there a way to programmatically link (in AS3) MovieClips to play one after the other? One I tried is at URL... and I have tried creating actionscript at last frame for each movieclip, but this goes directly into function I specify as an event at the time of creation (MovieClip.addFrameScript(MovieClip.totalFrames1, MyEventFunction) )
On one of the pages (In the site I'm designing) I have 4 buttons that need to link to 4 separate URLS. When I code one of the buttons, a link on another page is stopped.I guess what I'm asking is, what is the best way to 'layout' my button links in each page? And what is the best way to achieve 4 buttons with 4 different urls.
I am trying to put 3 buttons in a frame. I want each of themto act as a link to Web pages. If I use just the code forlink_btn_one it works great. If I include the code for the other 2it doesn't work. What am I doing wrong?Here's my code:
var link:URLRequest = new URLRequest(" http://www.skybooks.com"); link_btn_one.addEventListener(MouseEvent.CLICK, onClick);
I am a designer working on a flash project that is used to navigate to html pages. The project is a map - when you roll over different states there is an animation making that state pop out and show the state name. When you click each state (Button), it should open an html webpage. Right now the project works great, but I have the url's coded in flash actionscript using "onpress" and "load url." I would like to set it up so the flash file calls the URL for each button from an xml file, so it can be easily edited. The only thing it needs to call is the URL for each button. Can anyone give me simple instructions on how to make that happen?
How would you add a target="_self" function onto the buttons in this actionscript (as3) I need the buttons to open within the same browser window and not a new (_blank) window:
skype_btn.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler); function mouseDownHandler(event:MouseEvent):void { navigateToURL(new URLRequest("skype:mySkypeIdentifier")); } email_btn.addEventListener(MouseEvent.MOUSE_DOWN, mouseUpHandler); function mouseUpHandler(event:MouseEvent):void { navigateToURL(new URLRequest("mailto:myEmailAddresss@myDomain.com?subject=rts Esolutions enquiry")); }
I have a slide show swf file with an invisible button on the top frame. I would like this button to go to different URLs depending on what frame the movie is on when it is clicked. Is this possible?
The following works for one url: oneBtn.addEventListener(MouseEvent.CLICK, oneButtonFunction); function oneButtonFunction(event: MouseEvent) { var request:URLRequest = new URLRequest("http://webpage/"); navigateToURL(request); }
The reason I am trying to do it this way is I want the script to all be on one frame because I will be using this as a template for other slide shows and want to be able to edit the urls all in one window. I already have a slide show with key frames at the places where the new url would be accessed is click, but it is a pain to edit and add new content.
I'm building a flash app that gets rss links from a list but then I need to retrieve the rss feed from the rss link to work with in flash. I did this locally using a proxy.php wich works on all types of urls.
But on the server it only works with urls ending in .rss but not when it's a redirected url like .xml or other feedreader urls. How do I retrieve the rss from redirected urls on servers? Little sidenote, I made a test using a php form to call this proxy.php file that I made and when I use the urls that don't work in the flash app it does retrieve the rss feeds.
I'm building an mp3 player expressively to make my music URLs a little less steal-able. Forgive my hacking ignorance here, but would it be better to embed my playlist XML (with the URLs) in the SWF rather than having the SWF read the XML file from my server? Seems that the latter approach would be easier to intercept...
I'm pretty sure that no one wants my mp3s badly enough to decompile the code. But with the player currently at my site, my XML playlists -- with the URLs -- started to come up in Google searches. Would rather avoid *that* level of exposure.
im trying to find info about giving sections of my flash websites different urls.[URL]How do i code it so that a url can take me to a section of a flash website?
I've created a flash intro for a website and I have it setup so that in the first frame of the intro it opens a popup window, and then in the last frame it opens the actual site in the same window as the intro. Right now when it hits the last frame it opens up the popup window again also! Ack! The code I've used for opening the popup window is:var url:URLRequest = new URLRequest("player.html"); navigateToURL(url, "_blank");
the code used in the last frame to move to the site is:var urlReq:URLRequest=new URLRequest('index2.html');navigateToURL(urlReq,'_self');
I'm guessing that it has something to do with re-using the same variable name. I tried changing the code in different ways on the second window opening but still had the same result, or broke it opening up any pages at all. I've also tried moving the two code snippets to different layers. I'm thinking there might be a few ways around this too such as if there is a way to trigger the popup window, and then have the intro wait x seconds and then opens the main site or something, but I have no clue how to go about doing any of this. have the site in question in a temp location currently and it can be viewed here: [Url]
so i was trying to lop an Internet radio player, that will connect to different shoutcast servers, and play the radio, of course in development time everything was ok, now the time came for publishing just to be surprised with this messageof course i know what to do, but the end user will most likely won't know, and also i think this is a set back for developing such stuff, i also once tried to develop a twitter widget same thing happened when trying to communicate with twitter output, to work around that i could load the xml file from twitter into a local file using php, but i see a lot of flash files that uses flickr, twitter, and other sites, so how do these widgets work without triggering the security message,
I have assigned a different URL link to each button in my flash file, but receive the error "duplicate function exists" when tested. I tried renaming each function, but get an additional error, so that doesn't work either. Below is my code: