Any time I start a new ZF MVC project I am inevitably left with the unenviable task of bootstrapping a resource. I’m not particularly a fan of them but I’m still trying to drink the Kool-Aid. The problem is that getting a resource autoloader going seems to be a mind-numbing experience that leads to a line of code or two. So, rather than search for a project where I did it once before and then copy and paste the code into the project I figured I’d just blog about it so I can go here the next time I do it.
So, future idiot me,
When you have a project structure that looks like this
And you have an application config like this
resources.twitter.callbackUrl = "http://kschroeder/user/oauth" resources.twitter.siteUrl = "http://api.twitter.com/oauth" resources.twitter.consumerKey = "asdg425yasdfhjw46ujsfd" resources.twitter.consumerSecret = "g246REhnfdgnDFVGNdfJ6345683SDfSGHd" |
Add this to your application.ini
pluginPaths.Application_Resource = APPLICATION_PATH "/resources" |
Now, future Kevin, you will never need to go project searching again.
Comments
No comments yet...