Using asfunction to trigger actionscript from a URL link.

/ Published in: ActionScript
Save to your folder(s)

to call this function you would use "asfunction:myFunction,argument1,argument2,argument3" as the href in the tag in an HTML text box.

Copy this code and paste it in your HTML
  1. function myFunction(param){
  2. argumentArray = new Array;
  3. argumentArray = param.split(",");
  4. for (i=0; i< argumentArray.length; ++i){
  5. trace("Function argument " + i + " = " + argumentArray[i]);
  6. }
  7. }


Report this snippet


RSS Icon Subscribe to comments

You need to login to post a comment.