当前位置: 首页>>代码示例>>PHP>>正文


PHP Zend_View::dojo方法代码示例

本文整理汇总了PHP中Zend_View::dojo方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_View::dojo方法的具体用法?PHP Zend_View::dojo怎么用?PHP Zend_View::dojo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Zend_View的用法示例。


在下文中一共展示了Zend_View::dojo方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: _responseHtml

 /**
  * _responseHtml
  *
  * @return void
  */
 private function _responseHtml()
 {
     $body = $this->_viewRenderer->getResponse()->getBody();
     $respHeader = "{$this->_view->doctype()}\n        <html>\n        <head>\n        {$this->_view->headMeta()}\n        {$this->_view->headTitle()}\n        {$this->_view->headStyle()}\n        {$this->_view->headLink()}\n        {$this->_view->headScript()}\n        {$this->_view->dojo()}\n        </head>";
     $respBody = "<body>{$body}</body>";
     $respFooter = "</html>";
     $this->_viewRenderer->getResponse()->setBody($respHeader . $respBody . $respFooter);
 }
开发者ID:BGCX261,项目名称:zlayer-svn-to-git,代码行数:13,代码来源:Abstract.php

示例2: postDispatch

 /**
  * postDispatch
  *
  * @param  Zend_Controller_Request_Abstract $oRequest
  * @return void
  */
 public function postDispatch(Zend_Controller_Request_Abstract $oRequest)
 {
     // Vars
     $options = $this->_getOptions()->getMergedRequestOptions($oRequest);
     $front = Zend_Controller_Front::getInstance();
     // Dojo
     if (isset($options["dojo"])) {
         if (count($options["dojo"]) > 0) {
             $djOptions = $options["dojo"];
             if (isset($djOptions["djConfig"])) {
                 $array = array_merge($djOptions['djConfig'], $this->_view->dojo()->getDjConfig());
                 $this->_view->dojo()->setDjConfig($array);
                 unset($djOptions["djConfig"]);
             }
             $this->_view->dojo()->setOptions($djOptions);
         }
         Zend_Dojo::enableView($this->_view);
     }
 }
开发者ID:BGCX261,项目名称:zlayer-svn-to-git,代码行数:25,代码来源:Dojo.php

示例3: testResetResponseShouldClearAllViewPlaceholders

 public function testResetResponseShouldClearAllViewPlaceholders()
 {
     $this->testCase->getFrontController()->setControllerDirectory(dirname(__FILE__) . '/_files/application/controllers');
     $viewRenderer = Zend_Controller_Action_HelperBroker::getStaticHelper('viewRenderer');
     $viewRenderer->initView();
     $view = $viewRenderer->view;
     $view->addHelperPath('Zend/Dojo/View/Helper', 'Zend_Dojo_View_Helper');
     $view->dojo()->setCdnVersion('1.1.0')->requireModule('dojo.parser')->enable();
     $view->headTitle('Foo');
     $this->testCase->dispatch('/zend-test-php-unit-foo/baz');
     $response = $this->testCase->getResponse();
     $this->testCase->resetResponse();
     $view = new Zend_View();
     $view->addHelperPath('Zend/Dojo/View/Helper', 'Zend_Dojo_View_Helper');
     $this->assertFalse($view->dojo()->isEnabled(), 'Dojo is enabled? ', $view->dojo());
     $this->assertNotContains('Foo', $view->headTitle()->__toString(), 'Head title persisted?');
 }
开发者ID:sasezaki,项目名称:mirror-zf1-tests,代码行数:17,代码来源:ControllerTestCaseTest.php

示例4: prep_view

 /**
  *
  * @param Zend_View $pView
  * @return void
  */
 public static function prep_view(Zend_View $pView)
 {
     $pView->dojo()->addLayer(ZUPAL_BASEURL . DS . 'scripts/Dojo/dojo/grid_layer.js')->addStyleSheet(ZUPAL_BASEURL . DS . 'scripts/Dojo/dojox/grid/resources/Grid.css')->enable();
 }
开发者ID:BGCX262,项目名称:zupal-svn-to-git,代码行数:9,代码来源:Maker.php

示例5: setDojo

 /**
  * Set Dojo
  *
  * @return void
  */
 public function setDojo()
 {
     Zend_Dojo::enableView($this->_view);
     $options = array_change_key_case($this->getOptions(), CASE_LOWER);
     foreach ($options as $key => $value) {
         switch ($key) {
             case 'cdnbase':
                 $this->_view->dojo()->setCdnBase($value);
                 break;
             case 'cdndojopath':
                 $this->_view->dojo()->setCdnDojoPath($value);
                 break;
             case 'cdnversion':
                 $this->_view->dojo()->setCdnVersion($value);
                 break;
             case 'djconfig':
                 $this->_view->dojo()->setDjConfig($value);
                 break;
             case 'layers':
                 foreach ($value as $path) {
                     $this->_view->dojo()->addLayer($path);
                 }
                 break;
             case 'localpath':
                 $this->_view->dojo()->setLocalPath($value);
                 break;
             case 'modules':
                 foreach ($value as $module) {
                     $this->_view->dojo()->requireModule($module);
                 }
                 break;
             case 'stylesheets':
                 foreach ($value as $path) {
                     $this->_view->dojo()->addStylesheet($path);
                 }
                 break;
             case 'stylesheetmodules':
                 foreach ($value as $module) {
                     $this->_view->dojo()->addStylesheetModule($module);
                 }
                 break;
             default:
                 break;
         }
     }
     if (array_key_exists('enable', $options) && $options['enable']) {
         $this->_view->dojo()->enable();
     } else {
         $this->_view->dojo()->disable();
     }
 }
开发者ID:rockett,项目名称:parables,代码行数:56,代码来源:Dojo.php


注:本文中的Zend_View::dojo方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。