fuel / parser

Fuel PHP Framework - v1.x template parser package adapters
http://fuelphp.com
64 stars 45 forks source link

Workaround for issue #77 #78

Closed AssetsInc closed 9 years ago

AssetsInc commented 10 years ago

After initially trying to create an extension to work around the problem in the issue, I've been pointed to a more feasible approach on StackOverflow.

What I am doing here is adding each module in a name space, which allows to use {% extends @module/template.twig %} to extend/include specific module templates instead of the first one to be encountered along the view paths..

WanWizard commented 10 years ago

I'm not happy with this.

this may work for your use case, but totally wreck someone elses application. With no way to fix it, because paths are added in the code, with no option to alter this.

It isn't for nothing that a method exists for adding paths manually, and a config file with the paths. So if need need a custom list of paths, you should modify your config file, and add them there. You can use this exact same code for it.