src/Phlexible/Bundle/GuiBundle/Controller/AssetController.php
public function cssAction(Request $request)
    {
        $baseUrlContentFilter = $this->get('phlexible_gui.asset.base_url_content_filter');
        $baseUrlContentFilter->setBasePath($request->getBasePath());
        $baseUrlContentFilter->setBaseUrl($request->getBaseUrl());

        $cssBuilder = $this->get('phlexible_gui.asset.css_builder');

        $asset = $cssBuilder->build();

        $response = new BinaryFileResponse($asset, 200, array('Content-Type' => 'text/css;charset=UTF-8'));
        if ($asset->getMapAsset()) {
            $response->headers->set('X-SourceMap', $this->generateUrl('asset_css_map'));
        }

        return $response;
    }
public function cssAction(Request $request)
    {
        $baseUrlContentFilter = $this->get('phlexible_gui.asset.base_url_content_filter');
        $baseUrlContentFilter->setBasePath($request->getBasePath());
        $baseUrlContentFilter->setBaseUrl($request->getBaseUrl());

        $cssBuilder = $this->get('phlexible_gui.asset.css_builder');

        $asset = $cssBuilder->build();

        $response = new BinaryFileResponse($asset, 200, array('Content-Type' => 'text/css;charset=UTF-8'));
        if ($asset->getMapAsset()) {
            $response->headers->set('X-SourceMap', $this->generateUrl('asset_css_map'));
        }

        return $response;
    }
public function cssAction ( Request $ request ) { $ baseUrlContentFilter = $ this -> get ( 'phlexible_gui.asset.base_url_content_filter' ) ; $ baseUrlContentFilter -> setBasePath ( $ request -> getBasePath ( ) ) ; $ baseUrlContentFilter -> setBaseUrl ( $ request -> getBaseUrl ( ) ) ; $ cssBuilder = $ this -> get ( 'phlexible_gui.asset.css_builder' ) ; $ asset = $ cssBuilder -> build ( ) ; $ response = new BinaryFileResponse ( $ asset , 200 , array ( 'Content-Type' => 'text/css;charset=UTF-8' ) ) ; if ( $ asset -> getMapAsset ( ) ) { $ response -> headers -> set ( 'X-SourceMap' , $ this -> generateUrl ( 'asset_css_map' ) ) ; } return $ response ; }
Output css.

@param Request $request

@return Response
@Route("/gui.css", name="asset_css")
Output css .