Pragmatism in the real world

Dynamic Tabs Subversion Respository

With the help of Cliff, I've finally got a publically accessible subversion repository online at http://svn.akrabat.com! The first project with actual code in it is my Dynamic Javascript Tabs. I've updated the trunk to include the change suggested by Samio so that the "activation" code is not part of the js file and is not part of the htm file.

Zend_Config: Iteration and Arrays

An question about iteration, arrays and Zend_Config was posted to the Zend Framework's mailing list by Troy Marker. I thought I'd repeat it here as the solution shows how flexible Zend_Config can be. The post was: … First off I am using an XML file for the data: < ?xml version="1.0"?> <config> <lists> <root> <line1> <link>/index/show/gallery/cars/</link> <text>Cars</text> </line1> </root> </lists> </config> I am trying to iterate the file above to create a list in an… continue reading.

Zend Framework 0.1.4

Just in case anyone missed it, Zend Framework 0.1.4 is now out! This is an important release as it has Zend_Config in it, along with a host of other stuff :)

Overworked

I've been really really busy at work recently. With end of month coming up, we've been looking to complete jobs that can be invoiced this month, reduce work on jobs that won't be invoiced this month and add in a few "quick" jobs that can be invoiced this month. Can you tell that worrying about cashflow is part and parcel of being in a small company?! One result of all this is that I haven't… continue reading.

PHP Editors

Everyone has their favourite coding editor and as this topic has just come up on the Zend mailing list and comes up regularly on the Sitepoint forums, I thought I'd list the editors I use. For my main heavy lifting, I use Zend Studio. In my opinion, nothing can touch it's autocomplete functionality. I especially like the way that it uses phpdoc's @return construct for autocomplete on class objects that are returned from functions. Obviously,… continue reading.

Zend_Config: Array Reader

When casting around for another file format for Zend Config, I came up with XML or YAML. Obviously I posted to the mailing list for thoughts and Paul Jones suggested the completely obvious: PHP arrays! Another one, perhaps so obvious it is invisible, is a PHP array. Simple, straightforward, fast, no parser needed, open to programmatic manipulation. If it has not already been implemented, it would be trivial to do so. And he's right. One… continue reading.

Zend Framework: Incubator Testing

In case you missed it, the Zend Framework Subversion revision 532 is important as Darby has put in place the test harness fiiles required for testing the incubator code. Thanks Darby! For the tests to pass you must have the following on your include path: /path/to/PEAR /path/to/zend_framework/library /path/to/zend_framework/incubator /path/to/zend_framework/tests You can then run the tests from the incubator/tests directory using php -f AllTests.php. If you don't want to change your php.ini file, then php -d… continue reading.

Default Dirs

There's an interesting thread on the ZF mailing list called Default Dirs which deals with where to put your code. It's well worth a read. I've touched on this before, but thought I'd update my half a dozen readers on my current thinking :) The manual suggests: /application /models /views /controllers /document_root /images /styles .htaccess index.php /library /Zend My current directory stucture currently looks like: /application /models /views /controllers /schemas /tests config.ini /scripts /www /img… continue reading.

Zend_Config is in the Incubator

Just a quick note that the Zend_Config work I've been doing is now in the incubator within the official svn tree! (Trac link: http://framework.zend.com/developer/browser/trunk/incubator/library/Zend/Config) Thanks to Darby for sorting this out! Now everyone needs to go and bash on it and report bugs :)

Zend_Config Proposal v3: Akrabat_Config (8)

After discussion with Jayson on the Zend Framework's fw-general list and dealing with some excellent bug reports by Richard (aka OpenMacNews), I've come to the conclusion that the implementation of Akrabat_Config is wrong. I've redone it as two separate classes with no base class. We now have: Akrabat_Config Akrabat_Config_ini Akrabat_Config takes an associative array and provides read only access to it as properties properties . It also implements Countable and Iterator to make life easier.… continue reading.