MongoDB, Driver, Rocking
I do admit, yes, am rocking with MongoDB The simple adapter: https://github.com/xqpmjh/Trickle/blob/master/include/class.MongoAdapter.php But also, find a bug : https://bugs.php.net/bug.php?id=60508 To be continue…
SVN Setting eol-style
When using SVN in team coding, we need the unified end of file descriptor for all the repository files. Usually it’s LF(line-feed) which is the end of line char under linux. SVN has supportted this feature as svn:eof-style option, making all as easy as below. (1) Config file: For Win (usually): C:\Documents [...]
My Sweet Girl
Sometimes, some person, somethings, you feel dispointed, feel down… anything can frighten or block me as a protector?
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.
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 “scripts” and rename it to your cron job name, for example “cron.php”. 3. Modify the [...]
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 from https://github.com/jokkedk/ZFDebug, place it inside library just next to Zend Framework 2. Modify application/Bootstrap.php to add initialized [...]
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: We get a standard structure which is recommended by Zend Framework: It works very fine as “one” website project. But how about if we want to create multiple websites without rewriting too many code? The main idea is to share [...]
Replace Accents by Normal Unaccented in PHP
Sometimes we need the string to only contain unaccented characters, for example urls, xml, filename etc. Expecially before PHP6, You may think of function setlocale() and iconv(), but they are evil… If you’re writing code for yourself, to be used on a server you control, locales could be made to work if your [...]
Configurations of htaccess for Multi-Sites in Sharehost
It’s the htaccess configurations for multiple websites in sharehost. Cause sometimes you may not be able to modify apache vhosts.
Custom Url Helper for Zend View
Then for a user login url :