- Jaxer 1.0 or newer
Differences Between Firebug/FirePHP and This
The Firebug Console API lets you log multiple objects in one statement and use them with the string substition (i.e.
console.log("My object: %o", obj)). This implementation only lets you log a single object at a time. If the first argument to one of the functions is an object (that is, anything that responds with
"object" to the
typeof operator) it will be shown using FirePHP's Variable Viewer. If the list of arguments starts with a string or number, it will be logged as a text message.
These methods of the Firebug Console API are not currently implemented:
These features of FirePHP are not implemented:
Some of these will be implemented in future releases, others will not.
In addition, you can enable and disable messages from appearing with
- Download console.js and put it where your web files are stored.
- Include it in a page:
The console library is hosted at http://lib-console.appjet.net/. You can use it in your own AppJet applications by calling
An example page is hosted at http://console-test.appjet.net/.
<script src="console.js" runat="server"></script> <script runat="server"> console.log("Hello world!"); console.info("And", "so", "on"); </script>
As a Jaxer Extension:
Download the Jaxer extension and place it into your
local_jaxer/extensions directory. Once Jaxer is restarted, the
Jaxer.console object becomes available to all scripts. Usage is the same as above, except the script does not need to be included and
Jaxer.console is used instead of
Echoing to the Jaxer log can be enabled and disabled by setting
Jaxer.console.echo to true and false respectively.
These Boolean options can also be set in your
November 21, 2008
- Added AppJet support
November 20, 2008
- Added Jaxer extension
November 12, 2008
- Added ASP support
- Added MIT License and change log
- Fixed Jaxer toJSON bug
- Minor code cleanup
November 9, 2008
- Initial release
- If too many messages are logged in a given request, the server will not respond at all. What “too many” is depends on your platform. If your server does not respond, don't log so many messages or disable the console object. This threshold is reasonably high on ASP, and there is a bug report open for Jaxer.
- If you find any other problems or have any comments, please contact me.
This script would not have been possible without the help of these people:
- Christoph Dorn, for the FirePHP library
- Joe Hewitt, et. al. (did people make websites before Firebug?)
- The folks at webtoolkit.info, for their
- Davey at Aptana, and the whole Aptana staff for all of their help with Jaxer and the T-shirt