Zend Framework Forum

Go Back   Zend Framework Forum > Zend Framework General discussions > General Q&A on Zend Framework

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #11 (permalink)  
Old 06-14-2009, 11:41 PM
Junior Member
 
Join Date: Jun 2009
Posts: 1
Default

Quote:
Originally Posted by alokin View Post
Hi,
But when I try to use, for example Admin_Form_NewCategory, I get error Class Admin_Form_NewCategory not found...

What should I do?
You have to create extra bootstraps for each your module.
For example:
[PHP]
//application/modules/admin/Bootstrap.php
class Admin_Boostrap extends Zend_Application_Module_Bootstrap
{
//can be empty
}[/PHP]

Then your Admin_Form_NewCategory will work.

For more info, look there: Modular applications in ZF 1.8 mzBlog
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #12 (permalink)  
Old 10-17-2009, 07:36 PM
Junior Member
 
Join Date: Oct 2009
Posts: 1
Default

Quote:
Quote: Posted by leigh_m


Did you put the following in your application.ini:

resources.modules = ""

This worked for me.

I tried that before and it bombed out with some error. I'll try again tonight though.
I too was struggling with this and I put the issue aside to deal with other problems. Then I started implementing Module-level ini configurations following this post :

Zend Framework: module config | vandenbos.org

and discovered the solution to getting Module-level Bootstrap files to actually load.

The answer to the problem is not in any of the documentation I have read regarding Module implemention in Zend Framework. But all you need to do is to add 'resources.modules[] = ' to your application.ini file. This line will then enable the loading of your module Bootstrap.php files.

Remember to name the module-level Bootstrap class after your module. eg.
'class Admin_Bootstrap extends Zend_Application_Module_Bootstrap' or you will get an error about 'Cannot redeclare class Bootstrap'.

Hope this helps.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT. The time now is 03:25 PM.


Designed by: Miner Skinz Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0