本文整理汇总了PHP中Zend\View\Renderer\PhpRenderer::doctype方法的典型用法代码示例。如果您正苦于以下问题:PHP PhpRenderer::doctype方法的具体用法?PHP PhpRenderer::doctype怎么用?PHP PhpRenderer::doctype使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend\View\Renderer\PhpRenderer
的用法示例。
在下文中一共展示了PhpRenderer::doctype方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct($application)
{
$this->application = $application;
$sm = $this->application->getServiceManager();
$em = $this->application->getEventManager();
$this->view = $sm->get('ViewRenderer');
$this->view->doctype('HTML5');
$em->trigger('boostrap', $this->application, array(), array($this, 'onDispatch'));
return $this;
}
示例2: testGravatarHtmlDoctype
/**
* Test if doctype is HTML
*/
public function testGravatarHtmlDoctype()
{
$object = new Gravatar();
$view = new View();
$view->doctype()->setDoctype(strtoupper("HTML5"));
$object->setView($view);
$this->assertRegExp('/[^\\/]>$/', $this->helper->__invoke('example@example.com')->__toString());
}
示例3: testCsrfHtmlDoctype
public function testCsrfHtmlDoctype()
{
$object = new FormCsrf();
$view = new View();
$view->doctype()->setDoctype(strtoupper("HTML5"));
$object->setView($view);
$this->assertRegExp('/[^\\/]>$/', $object->__invoke());
}