all groups > flash actionscript > september 2005 >
You're in the

flash actionscript

group:

asfunctions


asfunctions icarusdown
9/11/2005 9:35:57 PM
flash actionscript:
Sometimes I just can't realize my ideas with flash... :-(

I am loading html formatted data in the dynamic text field using load vars.
In this html data i put some hyperlinks with asfunctions.

HTML LINK:

<a href ="asfunction:myFunction">link<a>

CODE:

function myFunction():void{
myLV.load("data_1.html");
}

I am using this asfunctions to load another html formatted data in the same
text field.
That is no problem.
But when I wrote 10 hardcoded functions I realize that there should be a nicer
way to do this because I don't want to mess with my flash files everytime I put
in another link (for example when I am updating my site).

I just want my site to be more dynamic, when it comes to updating.
I guess I have to write some code which is capable to do this via external
file (XML or PHP) .

Can someone give me a direction please.

THANK YOU IN ADVANCE

Re: asfunctions SuperSimon
9/12/2005 12:00:00 AM
What about something like this?

HTML LINK:
<a href ="asfunction:myFunction,page2.html">link<a>

CODE:
function myFunction(url):void{
myLV.load(url);
}

Re: asfunctions icarusdown
9/12/2005 8:37:22 AM
AddThis Social Bookmark Button