-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Placing view template outside of the 'Views' dir when using view() #180
Comments
I extended with my own (a little modification)
|
The directory option isn't a bad option to add (there's a 'cache' option available too), but might not be necessary for this. If your view is within a folder that's namespaced, you can treat it like a namespaced file. I think, though, it might be simpler just to get rid of the automatic folder portion and force the path to be full. So, no more Does that make sense? |
Yeah, I think I forgot something.... thanks! Good joob! :) |
Dear Council...
I have a question.
Can I place view template outside Views dir when I am using view() function?
I have dir structure like this:
or
My problem:
Normally (getting an error), the path sould be reference:
.../application/Views/App\Widgets/calendar.php
related:
System/Common.php
line 146 - 151And my feature request:
I like the third param of
view()
, as far as I know that supported only one variable key(bool) $options['saveData']
.view(string $name, array $data, array $options)
I think wit adding 'default dir' can be solve the problem and optional.
With 'defaultDir' key, optional values:
false
ornull
, if I don't want to use 'Views' dir.Exm:
My widget combined with view_cell() (I like this feature, thanks!):
I think
view()
only work for the controller class (correct me if I'm wrong).And, because it works perfect with my Blog module:
Hope you know what I mean.
Thanks!
The text was updated successfully, but these errors were encountered: