I only just recently started using Firebug (www.getfirebug.com.) It seems it's a popular way to debug JavaScript and HTML in Firefox. I use Firefox as my preferred browser, but working with Flex and Flash I rarely have to debug HTML or JavaScript. However, I was recently working on a project that required integrating ActionScript with a Move Networks media player, which requires a great deal of JavaScript. This gave me a reason to install Firebug, and I have to say that it's very cool. That's not really the point of this post, though. That's all just background information. Danny Patterson, a friend and colleague, recently blogged about how to log from Flex or Flash to Firebug. You can read the post on his blog. Basically, Firebug has a JavaScript API that you can call using ExternalInterface. For example, calling ExternalInterface.call("console.debug", "message from Flex"); will write a message to Firebug. Danny just put the ExternalInterface calls in a class that can be used with the Flex logging framework. Very neat.
Search
-
Recent Posts
Archives
Categories
Log From Flash or Flex to Firebug
May 23rd, 2008 by Joey