2017 © Pedro Peláez
 

package tracy-mysqli

This lib extends mysqli to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

image

dzegarra/tracy-mysqli

This lib extends mysqli to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  • Friday, February 24, 2017
  • by dzegarra
  • Repository
  • 1 Watchers
  • 0 Stars
  • 29 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 7 Forks
  • 1 Open issues
  • 5 Versions
  • 53 % Grown

The README.md

MySQLi panel for Tracy

This lib allow you to see all your executed SQL queries when you are using the MySQLi php driver. It also includes a Bar Panel for Tracy, see the result below., (*1)

Result

MySQLi logger with Tracy, (*2)

Installation

Install it via composer:, (*3)

composer require dzegarra/tracy-mysqli, (*4)

How to use

// Create an instance for Tracy Bar Panel
$panel = new \Dzegarra\TracyMysqli\BarPanel();

// Add the panel to Tracy
\Tracy\Debugger::getBar()->addPanel($panel);

// Make a connection to the DB using the \Dzegarra\TracyMysqli\Mysqli class instead of mysqli
$conn = new \Dzegarra\TracyMysqli\Mysqli("hostname", "username", "password", "database");

// Execute your queries

How it works

First you need to add the panel to the Tracy bar. The panel won't be render until the shutdown process kick in (either way the script ends or you call die or exit)., (*5)

Just before the panel start to render the list of all the SQL querys will be fetched from the Mysqli class., (*6)

All the queries are store in a static variable in the Mysqli so, no matters how many instances of the Mysqli class you create, all the queries of all the instances will be store., (*7)

Inspiration and credits

This repo is based in filisko/pdo-plus., (*8)

The Versions

24/02 2017

dev-master

9999999-dev

This lib extends mysqli to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  Sources   Download

MIT

The Requires

 

by Avatar daniel

logging mysqli tracy queries

24/02 2017

1.1.1

1.1.1.0

This lib extends mysqli to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  Sources   Download

MIT

The Requires

 

by Avatar daniel

logging mysqli tracy queries

24/02 2017

dev-feature/chg_implementation_to_mysqli

dev-feature/chg_implementation_to_mysqli

This lib extends mysqli to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  Sources   Download

MIT

The Requires

 

by Avatar daniel

logging mysqli tracy queries

15/02 2017

1.1

1.1.0.0

PDO plus extends PDO to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  Sources   Download

MIT

by Avatar Filisko

logging pdo tracy queries

31/08 2016

1.0

1.0.0.0

PDO plus extends PDO to allow you to see all your executed queries. It also includes a Bar Panel for Tracy

  Sources   Download

MIT

by Avatar Filisko

logging pdo tracy queries