Zend Framework - JQuery - Date Picker - Images not displayed

自闭症网瘾萝莉.ら 提交于 2019-12-12 01:54:22

问题


I am developing a web application with Zend Framework, and I am using JQuery for my forms. I have a problem with the DatePicker in a form. When I click on the text input, the DatePicker appears, but without the themes images...

In my bootstrap:

 $view->addHelperPath('ZendX/JQuery/View/Helper/', 'ZendX_JQuery_View_Helper');
                $viewRenderer = new Zend_Controller_Action_Helper_ViewRenderer();
                $viewRenderer->setView($view);
                Zend_Controller_Action_HelperBroker::addHelper($viewRenderer);

in my application/layout/scripts/layout.phtml:

    <?php echo $this->headLink()->appendStylesheet('http://localhost:10089/css/global.css') ?>

    <?php $this->jQuery()->setLocalPath('http://localhost:10089/js/jquery/jquery-1.3.2.js')
          ->addStylesheet('http://localhost:10089/js/jquery/themes/base/ui.datepicker.css');
      echo $this->jQuery();
    ?>

I guess it's a path problem somehow, but I do not see what's wrong here... I had a look at the ui.datepicker.css, and there is no link to the images folder, but when I run the demos delivered with the JQuery, the datepicker is displayed with its images...

Please help me!


回答1:


Ok found out what was wrong...

In layout.phtml:

  <?php $this->jQuery()->setLocalPath('http://localhost:10089/js/jquery/jquery-1.3.2.js')
               ->addStylesheet('http://localhost:10089/js/jquery/themes/base/ui.all.css')
               ->addStylesheet('http://localhost:10089/js/jquery/themes/base/ui.datepicker.css')
               ->addStylesheet('http://localhost:10089/js/jquery/themes/base/ui.core.css');
        echo $this->jQuery();
    ?>

the ui.all.css and core were missing....



来源:https://stackoverflow.com/questions/2243936/zend-framework-jquery-date-picker-images-not-displayed

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!