久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

  • <small id='ZCHHT'></small><noframes id='ZCHHT'>

    <i id='ZCHHT'><tr id='ZCHHT'><dt id='ZCHHT'><q id='ZCHHT'><span id='ZCHHT'><b id='ZCHHT'><form id='ZCHHT'><ins id='ZCHHT'></ins><ul id='ZCHHT'></ul><sub id='ZCHHT'></sub></form><legend id='ZCHHT'></legend><bdo id='ZCHHT'><pre id='ZCHHT'><center id='ZCHHT'></center></pre></bdo></b><th id='ZCHHT'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='ZCHHT'><tfoot id='ZCHHT'></tfoot><dl id='ZCHHT'><fieldset id='ZCHHT'></fieldset></dl></div>

    • <bdo id='ZCHHT'></bdo><ul id='ZCHHT'></ul>
    <tfoot id='ZCHHT'></tfoot>
        <legend id='ZCHHT'><style id='ZCHHT'><dir id='ZCHHT'><q id='ZCHHT'></q></dir></style></legend>

        Zend_Controller_Router_Exception:“xyz";未指定

        Zend_Controller_Router_Exception: quot;xyzquot; is not specified(Zend_Controller_Router_Exception:“xyz;未指定)
        <legend id='Y9gAD'><style id='Y9gAD'><dir id='Y9gAD'><q id='Y9gAD'></q></dir></style></legend>

            <tbody id='Y9gAD'></tbody>

            <i id='Y9gAD'><tr id='Y9gAD'><dt id='Y9gAD'><q id='Y9gAD'><span id='Y9gAD'><b id='Y9gAD'><form id='Y9gAD'><ins id='Y9gAD'></ins><ul id='Y9gAD'></ul><sub id='Y9gAD'></sub></form><legend id='Y9gAD'></legend><bdo id='Y9gAD'><pre id='Y9gAD'><center id='Y9gAD'></center></pre></bdo></b><th id='Y9gAD'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='Y9gAD'><tfoot id='Y9gAD'></tfoot><dl id='Y9gAD'><fieldset id='Y9gAD'></fieldset></dl></div>

                <small id='Y9gAD'></small><noframes id='Y9gAD'>

                <tfoot id='Y9gAD'></tfoot>
                  <bdo id='Y9gAD'></bdo><ul id='Y9gAD'></ul>
                • 本文介紹了Zend_Controller_Router_Exception:“xyz";未指定的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我當前的 Zend Framework 應用程序有問題.

                  I have a problem in my current Zend Framework application.

                  在我的 Bootstrap 中,我注冊了這些路由:

                  In my Bootstrap I register these routes:

                  protected function _initRouter()
                  {
                      $this->bootstrap("FrontController");
                      $frontController = $this->getResource("FrontController");
                  
                      $route = new Zend_Controller_Router_Route(
                          ":module/:id",
                          array(
                              "controller" => "index",
                              "action" => "index"
                              ),
                          array("id" => "d+")
                          );
                      $frontController->getRouter()->addRoute('shortcutOne', $route);
                  
                      $route = new Zend_Controller_Router_Route(
                          ":module/:controller/:id",
                          array("action" => "index"),
                          array("id" => "d+")
                          );
                      $frontController->getRouter()->addRoute('shortcutTwo', $route);
                  
                      $route = new Zend_Controller_Router_Route(
                          ":module/:controller/:action/:id",
                          null,
                          array("id" => "d+", "action" => "w+")
                          );
                      $frontController->getRouter()->addRoute('shortcutThree', $route);
                  }
                  

                  現在我將 Zend_Navigation 添加到我的項目中.我有幾個模塊,它們在模塊引導程序中注冊導航元素:

                  Now later I added Zend_Navigation to my project. I have several modules, that register navigation elements in the module bootstrap:

                  <?php
                  
                  class Contact_Bootstrap extends Zend_Application_Module_Bootstrap
                  {
                      protected function _initNavigation()
                      {
                          $layout = $this->getApplication()->getResource("layout");
                          $view = $layout->getView();
                  
                          $config = new Zend_Config_Xml(dirname(__FILE__)."/config/navigation.xml", "nav");
                  
                          $view->navigation()->addPage($config);
                      }
                  }
                  

                  當我在瀏覽器中打開應用程序時,一切正常.這意味著我可以看到導航并單擊其鏈接以查看指定頁面.但是當我點擊一個使用 :module/:action/:id 路由的頁面時,導航助手會拋出一個 Zend_Controller_Router_Route 異常:

                  When I open the app in my browser everything works fine. That means I can see the navigation and click on its links to view the specified page. But when I hit a page that uses the :module/:action/:id route, the Navigation Helper throws a Zend_Controller_Router_Route exception:

                  致命錯誤:Zend_Controller_Router_Exception: id is not specified in C:Entwicklungkt runksrclibraryendViewHelperNavigationHelperAbstract.php 第 519 行

                  Fatal error: Zend_Controller_Router_Exception: id is not specified in C:Entwicklungkt runksrclibraryendViewHelperNavigationHelperAbstract.php on line 519

                  你們中有人也遇到過這個錯誤嗎?如果你能幫助我或給我建議,那就太好了.另外,如果您需要有關我的設置等的更多信息,請告訴我.

                  Did anyone of you experience this error too? It would be great if you could help me or give me advise. Also if you need more information on my setup etc., just tell me.

                  謝謝!

                  推薦答案

                  我自己找到了解決方案.

                  I found the solution myself.

                  這個問題是由于 Zend_Navigation 元素的一個不那么有利的行為引起的.在他們的 getHref() 方法中,他們使用了 URL 助手.此幫助程序創建導航條目必須鏈接到的 URL,采用為導航元素(模塊、控制器、操作等)指定的參數.

                  This problem was caused due to a not-so-beneficial behavior of the Zend_Navigation elements. In their getHref() method they use the URL helper. This helper creates the URL the navigation entry has to link to, taking in the arguments specified for the navigation element (module, controller, action, etc.)

                  現在,問題是,例如,如果您像我一樣在引導程序中創建了自定義路由

                  Now, the problem is that, if you have created a custom route in your bootstrap just as I did, for example

                  ":module/:controller/:id"
                  

                  您遇到的問題是,當使用此路由時,URL 幫助程序使用該路由生成導航條目的鏈接.但是,我沒有傳遞額外的id"參數,所以我得到了異常.

                  You run into the problem that when this route is being used, the URL helper uses that route to generate the link for the navigation entry. However, I did not pass on an additional "id" parameter, so I got the exception.

                  因此,一種解決方案是為每個 Zend_Navigation_Page_Mvc 實例路由"傳遞一個附加參數,該參數設置為默認".

                  So one solution is to pass an additional parameter for each Zend_Navigation_Page_Mvc instance "route" which is set to "default".

                  我還沒有嘗試過的另一種解決方案是讓新的自定義路由將自身重新映射到默認路由上,例如:

                  Another solution, which I didn't try yet, is to let the new custom route just re-map itself onto the default route, like:

                  ":module/:controller/:action/id/$id"
                  

                  但我不知道您是否有能力使用 Zend Framework 做到這一點.

                  But I don't know if you have the ability with Zend Framework to do that.

                  這篇關于Zend_Controller_Router_Exception:“xyz";未指定的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  Deadlock exception code for PHP, MySQL PDOException?(PHP、MySQL PDOException 的死鎖異常代碼?)
                  PHP PDO MySQL scrollable cursor doesn#39;t work(PHP PDO MySQL 可滾動游標不起作用)
                  PHP PDO ODBC connection(PHP PDO ODBC 連接)
                  Using PDO::FETCH_CLASS with Magic Methods(使用 PDO::FETCH_CLASS 和魔術方法)
                  php pdo get only one value from mysql; value that equals to variable(php pdo 只從 mysql 獲取一個值;等于變量的值)
                  MSSQL PDO could not find driver(MSSQL PDO 找不到驅動程序)
                  • <tfoot id='e0Vvj'></tfoot>

                      <legend id='e0Vvj'><style id='e0Vvj'><dir id='e0Vvj'><q id='e0Vvj'></q></dir></style></legend>

                      <small id='e0Vvj'></small><noframes id='e0Vvj'>

                        <bdo id='e0Vvj'></bdo><ul id='e0Vvj'></ul>

                      • <i id='e0Vvj'><tr id='e0Vvj'><dt id='e0Vvj'><q id='e0Vvj'><span id='e0Vvj'><b id='e0Vvj'><form id='e0Vvj'><ins id='e0Vvj'></ins><ul id='e0Vvj'></ul><sub id='e0Vvj'></sub></form><legend id='e0Vvj'></legend><bdo id='e0Vvj'><pre id='e0Vvj'><center id='e0Vvj'></center></pre></bdo></b><th id='e0Vvj'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='e0Vvj'><tfoot id='e0Vvj'></tfoot><dl id='e0Vvj'><fieldset id='e0Vvj'></fieldset></dl></div>
                          <tbody id='e0Vvj'></tbody>
                            主站蜘蛛池模板: 97国产精品视频人人做人人爱 | 久久久www成人免费无遮挡大片 | 午夜三级网站 | 2020国产在线 | 免费中文字幕 | 国产精品久久久久久久久久免费看 | 免费成人在线网站 | 极品在线 | 在线观看www | 91精品国产乱码久久久久久久 | 日韩欧美亚洲 | av网站在线看 | 欧美日韩久久 | 国产成人免费视频 | 久久99精品久久久久久噜噜 | 一区二区国产精品 | 毛片免费在线 | 国产免费人成xvideos视频 | 精品欧美一区二区三区久久久 | 国产精品区二区三区日本 | 欧美一级做性受免费大片免费 | 亚洲一区二区久久久 | 一级片子| 欧美1区2区| 1区2区视频 | 国产精品美女久久久久久久久久久 | 一区二区三区四区在线 | 欧美成人精品在线观看 | 欧美一级大片免费看 | 日韩美av | 国产精品久久久久久一区二区三区 | 久久av在线播放 | 国产乱码久久久久久 | 成人三级视频 | 亚洲精品美女在线观看 | 精品欧美一区二区在线观看欧美熟 | 在线播放国产一区二区三区 | 国内自拍偷拍一区 | 欧美456| 欧美嘿咻 | av一区在线 |