Re: [firephp] Debug PHP ajax petitions?

69 views
Skip to first unread message

Christoph Dorn

unread,
Jan 17, 2015, 5:00:27 PM1/17/15
to fir...@googlegroups.com


You have to include FirePHP in FileBAjax.php as well.

Christoph



On January 17, 2015 01:59:21 pm PST, "Giuseppe Luigi Punzi"
<glp...@komenco.es> wrote:

> Hi,
>
> I have 2 files.
> - FileA.php
> - FileBAjax.php
>
> When FileA.php it's called, it builds an HTML UI and this UI via
> Javascript makes ajax petitions to FileBAjax.php
>
> Using....
> require_once('../FirePHPCore/FirePHP.class.php');
> ob_start();
>
> $fpDebug = FirePHP::getInstance(true);
> $fpDebug->log($somevar, "Some Text");
>
> Opening this file on my browser works and appears on console FP message.
>
> but when I click on some button, thath execute a JS calling my
> MyFileBAjax.php don't works.
> JS call is something like:
> function doSomethingAjax(){
> $.get("../MyFileBAjax.php",{opcion:"doSomethingB"},function (data)
> {
> code code code code code });
>
> }
>
> My FileBAjax.php basically is something like:
>
> $opcion = $_GET['opcion'];
>
> switch($opcion)
> {
> case "optionA":
> doSomething();
> break;
> case "optionB":
> doSomethingB();
> break;
> }
>
> Some idea if it's possible to get this working? I discovered today
> FirePHP and looks great for me. I have all development on "cloud",
> and this can let me debug better server side.
>
> -- You received this message because you are subscribed to the Google
> Groups "FirePHP" group.
> To unsubscribe from this group and stop receiving emails from it,
> send an email to firephp+u...@googlegroups.com.
> To post to this group, send email to fir...@googlegroups.com.
> Visit this group at http://groups.google.com/group/firephp.
> For more options, visit https://groups.google.com/d/optout.

Giuseppe Luigi Punzi

unread,
Jan 18, 2015, 3:38:30 AM1/18/15
to fir...@googlegroups.com
Hi, thanks for you your answer.

First,sorry, I reader this group is not maintained and writed after in forums.

About your answer, I will try today again, but I remember I tried to required firephp in both files and just a.php answers on console.
Reply all
Reply to author
Forward
0 new messages