google-code-export / firephp

Automatically exported from code.google.com/p/firephp
1 stars 0 forks source link

Output fails to show correct log items when page redirects #195

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What versions and operating system are you using?

OS: Xubuntu 13.04
Firefox: 21
Firebug: 1.11.4
FirePHP Server Library: Zend_Wildfire_Plugin_Firebug (Zend Framework 1.11.1)
FirePHP Extension: 0.7.2

What is the problem?

If you POST data to page B and page B redirects to page A, and both page 
responses send FirePHP messages, the output just duplicates the latest 
message(s).

What steps will reproduce the problem?
1. Enable FirePHP Database profiler in Magento
2. Submit a form which will redirect on success (like creating a CMS page or 
product).
3. View the FirePHP output in FireBug and see that there are no "INSERT" or 
"UPDATE" statements in there; however, inspecting the Net panel shows that the 
headers are being sent but not displayed.

What is the expected output? What do you see instead?

I expected to see two separate FirePHP entries in the output window: one for 
the POST request, one for the GET.  I instead saw two entries both for the GET 
request.

Please provide any additional information below.

There is no "easy" way to enable FirePHP in Magento.  I have a custom module 
which configures everything as described here: 
www.christophdorn.com/Blog/2008/09/02/firephp-and-zend-framework-16/  While I 
work in Magento, I believe this affects other places where a standard 
header('Location: /somwehere-else'); redirect is utilized.

While I'm not utilizing the FirePHP code itself, I believe the bug lies in the 
output display since on normal requests the headers work as expected.

I'm attaching the headers for the "double" request that exhibits this problem.

Original issue reported on code.google.com by b.a.patt...@gmail.com on 26 Jun 2013 at 5:34

Attachments:

GoogleCodeExporter commented 9 years ago
Updating file to include FirePHP output as displayed in console.

Original comment by b.a.patt...@gmail.com on 26 Jun 2013 at 5:40

Attachments:

GoogleCodeExporter commented 9 years ago
Attaching a simplified test case.  All this does is present a form with an 
input so you can specify the message you want to show up.  It then posts to 
itself and logs a few messages including the one you supplied and redirects 
back to itself.  In both instances, the output supplied in the console is the 
same message.

Attached are the index.php file I used to test with and the headers and content 
as recorded in FireBug's Net console (output.txt).

Original comment by b.a.patt...@gmail.com on 28 Jun 2013 at 2:02

Attachments:

GoogleCodeExporter commented 9 years ago
This is a known issue. There is no real fix for this as Firebug is page-based.

Not sure when there will be a solution for this.

Original comment by christ...@christophdorn.com on 28 Jun 2013 at 6:14

GoogleCodeExporter commented 9 years ago
I would like to believe you; however, it's curious as to why the message is 
duplicated if it's page-based.  It must see that there are two requests, which 
then begs the question, why not query the Net tab for all HTML/AJAX requests 
and parse those headers?

Original comment by b.a.patt...@gmail.com on 28 Jun 2013 at 6:20