1. Go to this page and download the library: Download manticora/rest-extra-bundle library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
manticora / rest-extra-bundle example snippets
php
/**
* @Get("notes", condition="compare(request.attributes.get('version'),'1', '<')")
*/
public function cgetAction()
{
return $this->getRepository()->findAll();
}
/**
* @Get("notes", condition="compare(request.attributes.get('version'),'1', '>=')")
*/
public function cgetNewVersionAction()
{
echo 'new version';
return $this->getRepository()->findAll();
}
bash
$ php composer.phar install
php
// app/AppKernel.php
public function registerBundles()
{
$bundles = array(
// ...
new Manticora\RestExtraBundle\ManticoraRestExtraBundle(),
);
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.