how to route subdirectory prenseters classes

Notice: This thread is very old.
alnux
Member | 139
+
0
-

Hi i cant deduce how to call presenters that are on subdirectory of presenters directory

app
....
.....
presenters
   Admin
      LoginPresenter.php

Last edited by alnux (2014-06-23 14:46)

amik
Member | 118
+
0
-

Directory structure does not matter at all, presenters are routed by class name (and namespace) only.
just the “presenters” directory must be somewhere where RobotLoader is configured to search classes, which is whole “app” directory by default in nette sandbox. So, if your “presenters” directory is not subfolder of “app”, that is the problem – RobotLoader can't find the presenter there (even without Admin subdir).

However, if you want to logically organize your presenters, I suggest using modules:

https://github.com/…odules-Usage