xolf/mysqldriver

There is no license information available for the latest version (dev-master) of this package.

A improved mysql driver for PhP

dev-master 2015-10-17 09:51 UTC

This package is not auto-updated.

Last update: 2024-05-11 15:46:04 UTC


README

A improved mysql driver for PhP

Connect to your database

$mysql = new ownMysql(MYSQL_HOST, MYSQL_USER, MYSQL_PASSWORD, MYSQL_DATABASE);

$mysql->connect();

Run a query

$mysql->query("SELECT `id` FROM `user` WHERE `name` = 'Test';");

Insert some data

$mysql->insert(array(
	'id' => NULL,
	'name' => 'Thomas',
	'mail' => 'test@example.com'.
	'phone' => 1516474747
	), 'user');

Error logging

If some query fails, the system will automaticly throw an exception with some further details. If you want to disable those error messages, exclude E_STRICT from error logging.