15th March 2006
I've updated Akrabat_Router to take advantage of a patch posted by Christopher Thompson on the fw-general list. I've also put in support for using traditional request variables so that I can have urls like http://localhost/zf_test/index.php?command=user&action=login etc. This is mainly for use with IIS as ISAPI_Rewrite costs money :)
The class now looks like this:
Read the rest of this entry »
Posted in PHP, Zend Framework | 11 Comments »
12th March 2006
I was going to look at storing content to the database having done collection of data from the database. However, in trying to that, it became obvious that I need to look at logging in too.
Looking at authentication first I decided to approach it using the Front Controller's Plugin system. However, having got half way into the implementation, I'm not convinced. Ideally you need finer control and only request for logging for specific controllers or actions. So, I've scrapped the Plugin, after having found a bug in Zend_Controller_Dispatcher_Token!, and am going to look at subclassing the Action, which seems now to the right place.
As usual, for me, the issue is trying to minimise the intrusion into the main code as authentication is just the "plumbing" by the you get to the actual code you want to write.
Posted in PHP, Zend Framework | 4 Comments »
9th March 2006
I've upgraded my test application to Zend Framework 0.1.2 and these are my notes:
I've changed my directory structure to match the one suggested in the manual. This involved moving a few files around, but nothing to major. I also changed all the paths in index.php to point at the new places.
The new directory structure looks like:
Read the rest of this entry »
Posted in PHP, Zend Framework | 9 Comments »
8th March 2006
The Zend Framework 0.1.2 is now out, so it's time to get out WinMerge and see what's changed :)
There's lots of changes, one of which I reported! Zend::loadClass() and Zend::loadInterface() now work with __autoload !
Other highlights are a lot of changes to the filter stuff and a few other changes to the other main modules.
I have only looked at the View and the Controller modules so far so will only comment on them.
Read the rest of this entry »
Posted in PHP, Zend Framework | No Comments »
8th March 2006
In case you missed it, 0.1.2 is out with documentation for the controller!
As I'm at work, I don't have a have a lot of time, but here's the highlights:
Read the rest of this entry »
Posted in PHP, Zend Framework | 4 Comments »
7th March 2006
Now that I have the semblence of a working system with views coupled up to our action controllers it's time to look at what the database classes do.
(I've uploaded some example code: ZF Test v2 to show that it all really works! Let me know if you find any bugs…)
As before, I'm looking to make my life easy when it comes to writing my applications. To understand what's possible, I'm going to play with the latestNews action that I created last time.
Read the rest of this entry »
Posted in PHP, Zend Framework | 3 Comments »
5th March 2006
Following on from my last post, I've now played with integrating Zend_View into the system. Whilst I was playing, I discovered that Nucleuz has put up a tutorial on wiki.cc. I quite like his approach, but needing to call
$this->display();
in every controller's action strikes me as a pain. Another problem is that you can forward from one action to another, and so the view needs to follow with you.
The approach in this entry is my first attempt (that works!) to satisfy my requirements of making handling the view as transparent as possible.
Initially, I thought that using the Front Controller's plugin functionality would be useful, except that the plugins have no access to the actual actions. Therefore, I went with Nucleuz idea of subclassing the Zend_Controller_Action.
Read the rest of this entry »
Posted in PHP, Zend Framework | 8 Comments »
4th March 2006
Zend have finally released a preview of their new framework at http://framework.zend.com/.
I've started having a play and their implementation of a Front Controller is quite similar to what I've been playing with. This isn't a total suprise as there aren't that many ways to do a Front Controller :)
The documentation on the Zend/Controller directory is completely non existant, so I've worked out the basics by reading the source. Fortunately, the source isn't too hard to read!
To get something going, I set up my directories like this:
Read the rest of this entry »
Posted in PHP, Zend Framework | 13 Comments »