Skip to content

Instantly share code, notes, and snippets.

View Ragdata's full-sized avatar
:octocat:
Preparing ...

Ragdata Ragdata

:octocat:
Preparing ...
View GitHub Profile
@tawfekov
tawfekov / generator.php
Last active March 2, 2024 16:06
Doctrine2 Generate Entities form Existing Database
<?php
include '../vendor/autoload.php';
$classLoader = new \Doctrine\Common\ClassLoader('Entities', __DIR__);
$classLoader->register();
$classLoader = new \Doctrine\Common\ClassLoader('Proxies', __DIR__);
$classLoader->register();
// config
$config = new \Doctrine\ORM\Configuration();