FirePHP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Pavilion
Forum Contributor
Posts: 301
Joined: Thu Feb 23, 2012 6:51 am

FirePHP

Post by Pavilion »

OK - I've just now found out about Firebug console. What a fantastic tool. I've been using it with my javascript and now want to use it with my php. So... I've figured out that I have to use FirePHP. I've downloaded the libraries and included the necessary files in my php files, but am not getting anything to show up in my console. Following is where I'm at right now:

File inclusion lines and a line to define $firephp - all as instructed:

Code: Select all

// include FirePHP files for debugging to the console.
require_once('../FirebugPHP/packages/core/lib/FirePHPCore/FirePHP.class.php');
require_once('../FirebugPHP/packages/core/lib/FirePHPCore/fb.php');
$firephp = FirePHP::getInstance(true);
Test effort to pass information to the console:

Code: Select all

$firephp->log('Plain Message');
$firephp->log('Hello World');
These lines do NOT return anything to the console.

Does anyone here have any idea what I'm doing wrong?

Thanks Much:

Pavilion
User avatar
Weirdan
Moderator
Posts: 5978
Joined: Mon Nov 03, 2003 6:13 pm
Location: Odessa, Ukraine

Re: FirePHP

Post by Weirdan »

Things to check:
1. Firebug must be open when you load the page (opening it after page load does not work)
2. Network tab in firebug must be enabled (disabled by default)
3. Firephp must be enabled (it's disabled by default)

If it still doesn't work, open the network tab, right click the request and post the results of 'copy request headers' and 'copy response headers' here.
Post Reply