मैं एक मॉड्यूल के अंदर अपने निर्देशिका संरचना के लिए कुछ इस तरह है:ज़ेंड फ्रेमवर्क 2 मॉड्यूल के अंदर आंशिक रूप से कैसे प्रस्तुत करता है?
Api
├── Module.php
├── config
│ └── module.config.php
├── src
│ └── (..etc ..)
└── view
├── api
│ └── api
│ └── index.phtml
└── partial
└── test.phtml
फिर, मैं यह कर रहा हूँ:
<?= $this->partial('partial/test.pthml', array()); ?>
हालांकि, मैं मिलता है:
05-Jun-2012 14:56:58] PHP Fatal error: Uncaught exception 'Zend\View\Exception\RuntimeException' with message 'Zend\View\Renderer\PhpRenderer::render: Unable to render template "partial/test.pthml"; resolver could not resolve to a file' in /Users/jeff/web/n/vendor/zendframework/zendframework/library/Zend/View/Renderer/PhpRenderer.php:463
कहां मेरे आंशिक जाना चाहिए?
आपका निर्देशिका संरचना की तरह सही है और अपनी आंशिक दृश्य सहायक सही ढंग से स्थापित किया जाएगा। बस सुनिश्चित करें कि आपके पास '' template_path_stack '=> array (' user '=> __DIR__।' /../ view ') है,' आपके 'module.config.php' फ़ाइल में जोड़ा गया है और आपको अच्छा होना चाहिए। –