简体   繁体   中英

how to display info in Firebug using Firephp

I am trying to display some info from a ajax call using firephp and firebug.I am able to display someinfo when the ajax call is done. Is there a way to display while it is executing? For example my code below id inside a foreach loop.

foreach ($this->PreQualcalls as $value) {    
ob_start();
if(isset($array ['env:Envelope'] ['env:Body']['n1:preQualResponse1207'])){
                $this->setKeyNamePreQualResponse("n1:preQualResponse1207");
                $this->setKeyNameServiceProducts("n1:ServiceProduct1207");
                $this->setKeyNameModemProducts("n1:ModemProduct1207");
                $this->firephp->log("entered the 1207 call");
            }else{
                $this->setKeyNamePreQualResponse("n1:preQual1308Response");
                $this->setKeyNameServiceProducts("n1:ServiceProduct1308");
                $this->setKeyNameModemProducts("n1:ModemProduct1308");
                $this->firephp->log("entered the 1308 call");
            }
ob_flush();
$this->firephp->log($this->getKeyNamePreQualResponse(),"Response type");
}

i want to be able to display getKeyNamePreQualResponse() in the console as it is being going through the loop.

Is it possible?

thank you.

FirePHP is designed to collect log information while the PHP script executes and then sends it in special headers along with the page response. It will not show logging calls in Firebug in realtime.

To debug your code using logging, place more logging calls into the loop. eg

$this->firephp->log("value", $value);

You have a loop that assigns a new value to $value on each iteration but don't use it in any of the statements in the loop. That does not seem right.

If you need realtime debugging I suggest using xDebug or other realtime logging tool.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM