To get started add phpcommerce/phpcommerce
as a composer dependency and add the following bundles to your Symfony project:
Add to your AppKernel.php
:
public function registerBundles()
{
$bundles = array(
//...
new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(),
new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new PHPCommerce\Bundle\PHPCommerceBundle()
);
return $bundles;
}
Add to your parameters.yml
:
parameters:
php_commerce.root_dir: %kernel.root_dir%/../vendor/phpcommerce/phpcommerce
php_commerce.database.driver: pdo_mysql
php_commerce.database.host: 127.0.0.1
php_commerce.database.port: 3306
php_commerce.database.name: phpcommerce
php_commerce.database.user: root
php_commerce.database.password: root
Import routes in your routing.yml
:
# app/config/routing.yml
phpcommerce:
resource: '@PHPCommerceBundle/Resources/config/routing.yml'
prefix: /