Category Archives: PHP

How to Overcome Zend_Cache_Frontend_Page’s Problem with Cookies

Zend_Cache_Frontend_Page First of all there are several things to know about Zend Framework and caching. Whenever you work on a big web application caching is one of the mostly used mechanisms of speeding up the app and improve user performance. … Continue reading

Posted in micro tutorial, PHP, zend framework | Tagged , , , , , , , , , , , , , , , , , , , , , , , | 3 Comments

Some PHP Tips: basename()

Here’s a quick tip: I’ve an absolute file path “/var/www/html/index.php”, but I need only the file name – index.php. So how do I get it? basename There it is: $filename = basename(’/var/www/html/index.php’); now $filename contains only “index.php”!

Posted in micro tutorial, PHP | Tagged , , , , | Leave a comment

Using PHP’s array_diff in Algorithm Development

array_diff can be really powerful. Once you’ve to find the different elements between two arrays you’ve to use array_diff. Here’s a case when you can use it while coding a simple algorithm. The Task You’ve one array with tickets of … Continue reading

Posted in micro tutorial, PHP | Tagged , , , , , , , , | 1 Comment

Construct a Sorted PHP Linked List

This is really a draft, but I somehow decided to post it. Here’s a simple linked list in PHP, where only the add() method is slightly different. When you have an item to add it’s placed on the “right” place … Continue reading

Posted in micro tutorial, PHP, web development | Tagged , , , , , , , , , , | 1 Comment

5 PHP String Functions You Need to Know

The Task First of all what we’d like to achieve? The task is to convert a string, most of the cases single word, by capitalize the first letter. In my case I’ve the world countries names all lower cased, while … Continue reading

Posted in micro tutorial, PHP | Tagged , , , , , , , , , , , , | 2 Comments