1
0
mirror of https://github.com/Mowie/Database-Class.git synced 2024-12-14 20:52:57 +00:00
Database-Class/example.php

26 lines
719 B
PHP
Raw Normal View History

2016-07-31 14:28:41 +02:00
<?php
require_once 'db-mysql.php';
$db = new db('localhost', 'testdb', 'root', 'supersecretpassword');
$db->setCol('blog');
//$db->data['id'] = 13;
//$db->get();
//print_r($db->get());
//print_r($db->data);
/*$db->data['titel'] = 'testdbclas';
$db->data['alias'] = '---d-d-d-d-';
$db->insert();*/
//if($db->insert(['titel' => 'testclass', 'inhalt' => 'baum', 'alias' => '0000003030498-g-dfghd-f'])) echo 'yay';
/*$db->data['titel'] = 'GAadsfhganz Neu';
$db->data['inhalt'] = 'gabs noch net';*/
//$db->update(['id' => 12]);
//if($db->update(['titel' => 'wat anderes', 'inhalt' => 'meh'], ['id' => 7])) echo 'update!';
//$db->data['id'] = 9;
//$db->delete();
//if($db->delete(['id' => 6])) echo 'del';
$db->clear();