Move it to bash completion scripts directory to be able to autocomplete zf providers and zf provider actions
Enable ItI you want to run it immediately in the same opened shell you can do the following command
Note: It will be automatically available in any new shell.
Custom Providers and Caching
In case you are wondering, I’ve got many projects with many custom providers, will it autocomplete them?
The answer is YES, and it fetches the providers per directory basis. Since the fetching and filtering is a pretty heavy process, it caches the autocompleted options in /tmp/ so that it will only be slow the first time, and then it’s going to be blazing fast.
Clear ZF autocomplete cache for providers and actions
To clear the cache, you will need to delete the cache files in tmp, the following command will do the job for you.
rm"/tmp/"`pwd|sed-e's:/:_:g'`"_actions" && rm "/tmp/"`pwd | sed -e 's:/:_:g'`"_providers"
What we want here is that a user can go to the localized version of the website according to the URL identified, for instance we want the website to load the English locale when we pass a URL like this http://example.tld/eng/Controller/Action
The problem is that while implementing the routes for the language detection, the plugins made a conflict with the rules in the routes file. Language routing is easy but sometimes can be tricky. Read more…
In this small article I’ll illustrate PHP’s variable variables and Variable constants. There is no variable constants in PHP but I’m introducing a methodology to implement the same approach and achieve the same functionality as variable variables. Read more…
After going here and there and implementing alot of solutions, I found that every post request is getting redirected to get even if it was with HTTPS because of the implementation of the ForceSSL in the manual, so my word to you, save your time and implement this simple solution. I have tested it on cakephp 2.0 however I think it wouldn’t mind to work on cakephp 1.3 Read more…
I came across a problem while developing with cakephp 2.0.
Suppose that you have got a Post model and a Category model, and you have a grid, with all posts and the category title they belong to. In order to sort by the category title you will need to do as the following in your view.
In this article I’ll go through resetting MySQL root password the easiest way
We are going to stop the MySQL daemon to be able to run it in safe mode, then we are going to skip grant tables, which means we are skipping password authentication, then we will set our new password Read more…