Creating a JSON-RPC service using Zend Json Server

In this post I am going to show how easy it is to create a JSON-RPC web service using the built in support in Zend Framework. First we need to create the php-file that will handle the incoming RPC calls. It is not advised to put this inside the MVC structure of a Zend web […]

Read more Creating a JSON-RPC service using Zend Json Server

Upgrading from Zend Framework 1.7 to 1.9 – The autoloader

Today I upgraded a project we started working on last year from Zend Framework 1.7 to Zend Framework 1.9. I excepted to run into several API incompatibilities, but the only problem I got was the autoloader. In Zend 1.7, and earlier versions, the autoloader was registered like this: require_once “Zend/Loader.php”; Zend_Loader::registerAutoload(); In Zend Framwork 1.9 […]

Read more Upgrading from Zend Framework 1.7 to 1.9 – The autoloader

Getting started with the Zend Framework

It used to be a bit tricky to get started with the Zend Framework. The Zend Framework is very flexible and allows you to set it up in almost any way that fits your needs. This means for example that the directory structure and location of files is up to you, however – there is […]

Read more Getting started with the Zend Framework

Friendly URLs and the Zend Router

Creating custom friendly URLs using the Zend framework is really simple. The default routing setup for Zend is : ‘:module/:controller/:action/*’, (* will match any var/value) which is fine for most setups. However on some pages having the var/value might not look very good, for example this url is not very readable: /popular/index/type/images/page/1/sortOrder/alltime (controller/action/var/value/var/value/var/value) We would […]

Read more Friendly URLs and the Zend Router

Creating a custom View Helper in the Zend Framework

Zend Framework ships with several View Helpers, such as the url View Helper. Anywhere in a view script one can call $this->url() to generate a url to a certain page. For example: $this->url(array(   ‘module’ => ‘moduleName’,   ‘action’ => ‘actionName’,   ‘additionalParam’ =>’value’)) I wanted to create my own helper, for generating paths to thumbnails, and it […]

Read more Creating a custom View Helper in the Zend Framework