26 lines
353 B
PHP
26 lines
353 B
PHP
<?php
|
|
|
|
namespace Core\Database;
|
|
|
|
use \PDO;
|
|
|
|
class QueryBuilder
|
|
{
|
|
protected $pdo;
|
|
|
|
public function __construct(PDO $pdo)
|
|
{
|
|
$this->pdo = $pdo;
|
|
}
|
|
|
|
public function prepare($query)
|
|
{
|
|
return $this->pdo->prepare($query);
|
|
}
|
|
|
|
public function lastInsertId()
|
|
{
|
|
return $this->pdo->lastInsertId();
|
|
}
|
|
}
|