String Cutting Helper in Zend Framework
It's the string cutting helper which deal with both UTF8 and others encodings. Also it remove html tags by default. [codesyntax lang="php" lines="no"] /** * Takes a string and optionally a maximum len… Continue reading
Cron Job Script in Zend Framework
To create a cron job script in Zend Framework, we just need 3 steps : 1. Create a new directory called "scripts" which is the storage of all the scripts(.sh, .php, etc.). 2. Copy public/index.php into… Continue reading
Setup ZFDebug for Debuging your Zend Framework Project
"ZFDebug is a plugin for the Zend Framework for PHP5, providing useful debug information displayed in a small bar at the bottom of every page." We just need two steps to setup ZFDebug: 1. Download it … Continue reading
Create Multiple Websites with One Shared Library by Zend Framework
When we try to generate the project by Zend_Tool by command line like this: [codesyntax lang="bash" lines="no"] $ zf create project myProject [/codesyntax] We get a standard structure which is recomme… Continue reading
Custom Url Helper for Zend View
[codesyntax lang="php"] /** * url helper * * @author kim */ class App_View_Helper_L extends Zend_View_Helper_Url { /** * the current module */ static $currentModule = null; /** * Generate the link for… Continue reading
Simple Wrapper of Zend Controller
My simple wrapper of Zend Controller. It has 5 features including getParam, redirector, json and flash message. [codesyntax lang="php" lines="no"] /** * class App_Controller_Abstract * * @author kim *… Continue reading
Zend Framework 2.0 Roadmap Review
Being one of the most famous PHP frameworks in the world, Zend Framework has set up its roadmap for version 2.0. As ZF 1.10 may certainly be the final release of 1.x branch, we are now going to be foc… Continue reading
Registry Pattern in Zend Framework
The registry has provided a mechanism which help you to store and maintain your objects within the application. It's aim at preventing improperly using the global objects by users. The registry usuall… Continue reading
Singleton Pattern in Zend Framework
The singleton provides a very good solution to the problem when you need an object to be handled as always single and global. Singleton, which may usually merge up with other patterns (e.g. registry, … Continue reading
Factory Pattern in Zend Framework
The factory pattern is a simple but powerful design pattern which makes it very easy to manage and maintain plenty of classes. The factory pattern, as it means, is using some material to provide produ… Continue reading
Create Captcha Image with Zend_Dojo
Users usually see the captcha and are asked to type the same in order to prove their truth when they are just going to take the registration. Zend_Captcha in Zend Framework provides this kind of funct… Continue reading
Custom View Helper in Zend Framework
Zend Framework which is built on MVC design pattern has also provided lots of it's accessories. The view helper is one of them. The view helper, as it named, is to help the view to complete it's work.… Continue reading
Builder Pattern in Zend Framework
When we want to implement one thing in different ways, we think of builder design pattern. It's like a building, when, design has been done, though handled by different engineers directing different c… Continue reading
Practise dojox.grid.DataGrid with Zend_Dojo
Zend_Dojo was released together with Zend Framework 1.6 as well as Dojo toolkit package . We can make a good experience of the client-side with powerful Dojo components through a simple API provided b… Continue reading
Multi-modules and multi-templates application for Zend_Application
At the very beginning I need to introduced everybody of Zend_Application before doing anything. As one of the most important big changes in Zend Framework 1.8, the Zend_Application has introduce two n… Continue reading
Iterator Pattern in Zend Framework
The Iterator design pattern has provided a common mechanism for accessing collections. It allow user to traversal, access, and manipulate data sets, such as array, files, RSS feeds and database result… Continue reading
Strategy Pattern in Zend Framework
In the traditional process-oriented languages are often filled with a lot of if/else statements. This situation has easily made the logic of chaos and trouble to amend. The strategy design pattern was… Continue reading
Caching application.ini for Zend Framework apps
In most of the time we build our application using Zend Framework, we make index.php as the entry which creates the object of Zend_Application and it's configurations such as Application.ini. But it's… Continue reading
404 and 500 errors in Zend Framework
First of all, I want to review the several mechanisms that Zend Framework provide to handle exceptions in it's MVC components. 1. Pass the exceptions to Zend_Controller_Plugin_ErrorHandler. 2. Using Z… Continue reading
Sending all css and js in one request
As we all know, one thing which mainly slow down our site is the plenty of css and js files. But very often we have to make them seperate from each other in order to facilitate management. The problem… Continue reading
htaccess in Zend Framework
How to setting up your .htaccess for your application is always become a question which hard to answer. In this note, we will take a look at it, fully and detail by detail. Hope it to be useful. The u… Continue reading
Setting Up Zend Framework
How to setting up your Zend Framework environment? This is an old question since 1st version released at 1st July, 2007. Here I will show you some of my experience as much as possible. 1. php set up P… Continue reading
Zend Framework performance optimize – Class Loading
Zend Framework is poweful with out questions. It has provided full-featured class library and components. But one thing also become a problem at the same time when Zend Framework show greatly convenie… Continue reading