Skip to content

Instantly share code, notes, and snippets.

@cstrahan
Created October 27, 2010 10:36
Show Gist options
  • Save cstrahan/648799 to your computer and use it in GitHub Desktop.
Save cstrahan/648799 to your computer and use it in GitHub Desktop.
AS3 alert function.
// Just for future reference,
// here's a quick way to interface with the browser's Javascript `alert' function.
import flash.external.ExternalInterface;
private function alert(text:String):void
{
text = text.replace(/\\/g, "\\\\");
ExternalInterface.call("alert", text);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment