Raffler Bundle
This bundle is a simple backbone.js + Symfony2 app created using https://github.com/gigo6000/DevtimeBackboneBundle, it also uses Twitter bootstrap., (*1)
It allows you to get a ramdom winner from a list of names., (*2)
Follow @gigo6000 on Twitter. Tweet any questions or suggestions you have about the project., (*3)
What you need
This bundle requires Symfony 2.1.1 or greater (it probably works in older versions but not tested), (*4)
Installation
Step 1: Download DevtimeRafflerBundle using composer
Add DevtimeRafflerBundle to your composer.json:, (*5)
{
"require": {
"devtime/raffler-bundle": "dev-master"
}
}
Now tell *composer to download the bundle by running the command:, (*6)
``` bash
$ php composer.phar update devtime/raffler-bundle, (*7)
Composer will install the bundle to your project's `vendor/devtime` directory.
* Note: If you don't have Composer yet, download it following the instructions on
http://getcomposer.org/ or just run the following command:
``` bash
curl -s https://getcomposer.org/installer | php
Step 2: Enable the bundle
Enable the bundle in the kernel:, (*8)
``` php
<?php
// app/AppKernel.php, (*9)
public function registerBundles()
{
$bundles = array(
// ...
new Devtime\Bundle\RafflerBundle\DevtimeRafflerBundle(),
);
}, (*10)
### Step 2: Import routes
Import the bundle routes by adding the following code to your applicationâs routing file:
``` yml
# app/config/routing.yml
devtime_raffler:
resource: "@DevtimeRafflerBundle/Controller/"
type: annotation
prefix: /
Step 3: Publish the bundle assets
After this you need to install (publish) your assets to the web dir., (*11)
bash
php app/console assets:install
, (*12)
At this point you should be able to see the app: http://yoursite.local/raffler., (*13)