Neos\FluidAdaptor\View\StandaloneView::setFormat PHP Метод

setFormat() публичный Метод

Sets the format of the current request (default format is "html")
public setFormat ( string $format ) : void
$format string
Результат void
    public function setFormat($format)
    {
        $this->baseRenderingContext->getControllerContext()->getRequest()->setFormat($format);
    }

Usage Example

 /**
  * Prepare a Fluid view for rendering an error page with the Neos backend
  *
  * @return StandaloneView
  */
 protected function prepareFluidView()
 {
     $fluidView = new StandaloneView();
     $fluidView->setControllerContext($this->runtime->getControllerContext());
     $fluidView->setFormat('html');
     $fluidView->setTemplatePathAndFilename('resource://Neos.Neos/Private/Templates/Error/NeosBackendMessage.html');
     $fluidView->setLayoutRootPath('resource://Neos.Neos/Private/Layouts/');
     // FIXME find a better way than using templates as partials
     $fluidView->setPartialRootPath('resource://Neos.Neos/Private/Templates/TypoScriptObjects/');
     return $fluidView;
 }
All Usage Examples Of Neos\FluidAdaptor\View\StandaloneView::setFormat