1

Moved database from "production" server to development, all code is the same. Custom layouts for adminhtml stopped firing, get just a header and footer, content in the middle not being loaded. When I switch local.xml back to the original database, everything works. Is there anything in the database that might be preventing this from firing? cleared cache, compile and all else I could think of. Grids and standard admin pages work as expected. No errors in any of the logs.

Config.xml

<adminhtml>
    <layout>
        <updates>
            <hubco_pu>
                <file>hubco_pu.xml</file>
            </hubco_pu>
        </updates>
    </layout>
    <acl>
        <resources>
            <admin>
                <children>
                    <system>
                        <children>
                            <config>
                                <children>
                                    <pu_options>
                                        <title>WPS Config Options</title>
                                    </pu_options>
                                </children>
                            </config>
                        </children>
                    </system>
                </children>
            </admin>
        </resources>
    </acl>
</adminhtml>

hubco_pu.xml

   <?xml version="1.0" ?>
<layout version="0.1.0">
    <hubco_pu_admin_manual_index>
        <reference name="content">
            <block type="hubco_pu/manual" name="index" template="hubco/pu/manual.phtml" />
        </reference>
    </hubco_pu_admin_manual_index>
</layout>

Controller file:

    class HubCo_Pu_Adminhtml_ManualController
    extends Mage_Adminhtml_Controller_Action
{

    public function indexAction()
    {
        $this->loadLayout();
        $this->renderLayout();
    }

Block class:

class HubCo_PU_Block_Manual
    extends Mage_Core_Block_Template
{
  function HubCo_PU_Block_Manual() {

    include '/var/www/elmagento/app/design/adminhtml/default/default/template/hubco/pu/manual.phtml';
  }
  protected function getHello() {
    return "Hello world!";
  }

  public function getCreateUrl($url, $parameters = array())
  {
    /**
     * Generate the URL for the action we want.
     */
    return Mage::helper("adminhtml")->getUrl($url,$parameters);
  }
}

This displays the phtml file on top of all else in the page using the include (so the file is accessible by the server). For some reason the layout XML is not being processed correctly, I checked and the Action Name is correct.

Any help would be appreciated.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.