Created
September 2, 2015 21:07
-
-
Save wizhippo/eca58cd9ebc6fff7b1a6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace TestBundle\Command; | |
use Doctrine\DBAL\Connection; | |
use GuzzleHttp\Client; | |
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand; | |
use Symfony\Component\Console\Input\InputInterface; | |
use Symfony\Component\Console\Output\OutputInterface; | |
class TestSiteAccessCommand extends ContainerAwareCommand | |
{ | |
/** | |
* @inheritdoc | |
*/ | |
protected function configure() | |
{ | |
$this | |
->setName('assocsite:testsiteaccess') | |
->setDescription('Show site access'); | |
} | |
protected function execute(InputInterface $input, OutputInterface $output) | |
{ | |
$container = $this->getContainer(); | |
$siteAccess = $container->get('ezpublish.siteaccess'); | |
$siteAccessDefault = $container->getParameter('ezpublish.siteaccess.default'); | |
$siteAccessDefaultName = $container->getParameter('ezpublish.siteaccess.default.name'); | |
print_r($siteAccess); | |
print_r($siteAccessDefault); | |
print_r($siteAccessDefaultName); | |
$var_dir = $container->get('ezpublish.config.resolver')->getParameter('var_dir'); | |
print_r($var_dir); | |
return 0; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment