Get URL of the Page Where SWF is Embedded


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



Copy this code and paste it in your HTML
  1. function get currentURL():String
  2. {
  3. var url:String;
  4. if (ExternalInterface.available) {
  5. return ExternalInterface.call("window.location.href");
  6. }
  7. return url;
  8. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.