Skip to content

Instantly share code, notes, and snippets.

@ahilles107
Created October 26, 2012 12:44
Show Gist options
  • Save ahilles107/3958564 to your computer and use it in GitHub Desktop.
Save ahilles107/3958564 to your computer and use it in GitHub Desktop.
Newscoop Latest Articles Widget - silex simple app.
<?php
require_once __DIR__.'/../vendor/autoload.php'; // Composer autoloading
$app = new Silex\Application();
// register twig support
$app->register(new Silex\Provider\TwigServiceProvider(), array(
'twig.path' => __DIR__.'/Resources/views',
));
//debug
$app['debug'] = true;
//create route
$app->get('/', function (){
return "Newscoop widget";
});
$app->run();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment