EzDevInfo.com

php-debugbar

Debug bar for PHP PHP Debug Bar

How to increase request timeout in IIS7.0 by php script

How to increase script execution time. I have already use this function in my script.

ignore_user_abort(true);
set_time_limit (10800);
ini_set('max_execution_time', 10800);
ini_set('max_input_time', 10800);
ini_set('max_input_nesting_level', 10800);
ini_set('max_input_vars', 10800);

I have not server access for change anything and For your information my PHP script Running without safe mode. So what I do for increase script execution time. Any suggestion for me...


Source: (StackOverflow)

Laravel 4 and debugbar - show pdo queries?

I have installed: https://github.com/barryvdh/laravel-debugbar using composer.

I followed install procedures, and now done.

But how do I see my PDO mysql queries? I am building a RESTful api, without any HTML/view rendering.

Don't know if it is for any use, but heres some example of my code:

    // the controller
    public function feed($exclude = null) {

        $feed = $this->item->feed()->with('attributes', 'images', 'user');

        if($exclude)
            $feed->whereNotIn('id', explode(',', $exclude));
        return ['items' => $this->itemTransformer->transformCollection($feed->get()->toArray())]; // woud like to debug this query
    }

    // the router
    Route::get('items/feed/{exclude?}', ['protected' => true, 'uses' => 'ItemsController@feed']);

Source: (StackOverflow)

Advertisements

How to add HTML to PHP Debug Bar indicator tooltip?

This question pertains to PHP Debug Bar.

I'm adding a custom DataCollector to PHP Debug Bar. I want to add some nicely formatted information to it when I mouse over it. For example,

public function getWidgets() {
    $name = $this->getName();
    $hg_changeset = rtrim(`/usr/local/bin/hg id -i`,"\n+") ?: '(unavailable)';
    $hg_branch = rtrim(`/usr/local/bin/hg id -b`,"\n") ?: '(unavailable)';
    return array(
        $name => array(
            "icon" => "leaf",
            "tooltip" => "Changeset: $hg_changeset\nBranch: $hg_branch",
            "map" => $name,
            "default" => json_encode("Unknown"),
        )
    );
}

Renders like this:

enter image description here

Is there a way I can put HTML in the tooltip? It seems to autoescape it.


Source: (StackOverflow)

Laravel-Debugbar not catching AJAX call (Angular call)

I am working on project which front end is AngularJS & Backend is Laravel4.

And I am using barryvdh's laravel-debugbar package as debugger

My problem is debugbar showing data when first time load page or i refresh page

But is is not catching when i call api throw angular resourse.

I tried AJAX call configuration as posted in documentation but still not working.

In config file:-

/*
     |--------------------------------------------------------------------------
     | Capture Ajax Requests
     |--------------------------------------------------------------------------
     |
     | The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors),
     | you can use this option to disable sending the data through the headers.
     |
     */

    'capture_ajax' => true,

And In My Controller:-

        Debugbar::addMessage('Another message', 'mylabel');
        Debugbar::warning('Watch out..');
        Debugbar::sendDataInHeaders();

-ND


Source: (StackOverflow)

Using Laravel Debugbar, how can I disable exception logging?

I'm using the Laravel Debugbar Package to display debug information. I'm noticing that the debug bar is logging errors to the log whenever an exception occurs. I would rather this doesn't happen, since I am running my own custom exception handler which collects information in the format I prefer and I have it logging to the log file as well.

So for example when I mistype a route name, I get the message saved twice to the log file:

[2015-02-11 16:21:02] local.ERROR: Method [fdfdgfd] does not exist.

[2015-02-11 16:21:04] local.ERROR: Debugbar exception: Method UserController::fdfdgfd() does not exist [] []

How can I disable exception logging with the Debugbar?


Source: (StackOverflow)

Laravel best practices to setup debugbar

I have laravel project, in which I fetch data which are database cursors and the data embedded in them. I want to inspect the data. What is right setup ?


Source: (StackOverflow)