Skip to main content
October 16, 2007
Question

Info in URL

  • October 16, 2007
  • 32 replies
  • 2207 views
Heres my story

So i have a flash file that has a text box with a scroll bar
thats all the flash file is...just a text box with a scroll bar attached

well i would like to do two different things, totally different
lol

heres number 1:
i have seen in many flash countdowns and stuff that is embeded, the url looks like this, for example:

http://i93.photobucket.com/albums/l80/bigrollerdave/flash/countdownred.swf?da=03&mo=01&words=bday"

If you look after the file is located, it says countdownred.swf?...
it has the extra info that gives the countdown what it needs
For my flash file, i would like to have something like that that would give the flash file the text it needs to be put in the flash file.
so the url would be like:
http://mysite.com/scrollbar.swf?text=this text appears in the scroll bar"


the second thing i would like to do it make a text file with the text, and make the text file in the url so that the text in the text file would be what appears in the scroll bar
so it would be somethin like:
http://mysite.com/scrollbar.swf?text=http://mysite.com/text.txt"
This topic has been closed for replies.

32 replies

October 18, 2007
Assuming you are using AS1 or AS2:

myflash.swf?frame=500

would be accessed by a frame script on the main timeline in Flash simply by:

frame
or from anywhere in your movie as the fully qualified:
_root.frame

So you could use gotoAndPlay(frame)
October 18, 2007
so the code i attached was found in the help section of flash 8

this is kinda what i wanted, it made a textbox and then grabbed the text that was in the txt file and put it in that text box

A. i kinda wanted to be able and put it at the end of the flash embed
and
B. when i do that, like i said, it makes a text box and puts the text in it
but what it doesn do is make it scroll
i wanted it to be able and scroll

is there a way i can make a text box already in it, and like you said make a string or w/e and so it can be scroll?
October 17, 2007
When you have a querystring on a .swf file like that, the variables get dumped as strings on the main timeline (AS1 and AS2) or in the loaderInfo.parameters object (AS3).

Then once you have the variable, say "text" you can use LoadVars, loadVariables, or loadVariablesNum (AS1 and AS2) or a URLLoader (AS3) to load the text, then assign it to your textfield's .text property.
October 17, 2007
k so i guess i semi get that

but im such a noob when it comes to flash
so can you explain it in like plain english, lol or just give me the actionscript code that goes on the frame, since theres only one frame
unless i need more...

thanx for you help!