Heres what i would like to do
i have a small flash file with a dynamic text field with instance name: load_txt
i have a server…http://myserver.com
what i would like to be able to do is when embedding my flash file with the empty text field, put a “?” after the .swf and then put something like “url”
with that, in the actionscript i would have it set to go to:
http://myserver.com/“url”.txt
so if i did
the flash file would load, and whatever would be in:
http://myserver.com/ben.txt
would load into the text field in the flash
i would already have the url labeled, just need to place the name of the txt file in the .swf? and then it would load properly
im sure it would be easy to do…
i have this code:
var man_laws:LoadVars = new LoadVars();
man_laws.onData = function(src:String):Void {
if (src != undefined) {
my_txt.text = src;
} else {
man_laws.load("http://manlaws.tripod.com/manlaw.txt");;
}
};
if(_root.url== undefined){
_root.url = "http://manlaws.tripod.com/manlaw.txt";
}
man_laws.load(_root.url);
as you can see…i could do this:
test.swf?url=http://manlaws.tripod.com/manlaw.txt
whatever was in that text file would load into the flash
what i want to do is be able to say
test.swf?url=manlaw
and have the link already defined
so it would load the file “http://manlaws.tripod.com/” + whatever i enter into url + “.txt”
thanx for your help!
ATTENTION!
i got it to work
var man_laws:LoadVars = new LoadVars();
man_laws.onData = function(src:String):Void {
if (src != undefined) {
load_txt.text = src;
} else {
man_laws.load("http://ben-beadle.tripod.com/" + url + ".txt");;
}
};
man_laws.load(_root.url);
now what i would like it to do is scroll across the screen
any ideas?