debugging - How do you log to Firebug from an extension? -


I am writing an extension for Firefox, and I have to log some data into the FireBox console, under the scope of my addon Within, "console" is undefined, and "window.content.console" is also undefined. So how do I access the console?

Since you are not writing javascript that executes in a window, console is not defined.

So you first need to refer to the firebug extension:

  Firebug.Console.log (str);  

Comments

Popular posts from this blog

email - PHP mail error ... failed to open stream : permission denied -

sql server - SQL Query - Delete duplicates if more than 3 dups? -

c# 3.0 - Issue with getting 2 chars from string using indexer -