Google Shared Stuff allows one to easily get the Favicon of any website with a single line. For instance to get the Favicon of yahoo.com we can use the following in a browser. http://www.google.com/s2/favicons?domain=yahoo.com We can do do the same using PHP and curl using the following code.
During debugging the majority of my time is spent in searching for specific text. Searching on the local machine is a breeze via a IDE, but if I’ve an application hosted on a remote server then it can get difficult and slow, unless of course you have access to SSH when you can use good-old [...]
Shopping carts are one of the most frequently used parts on the web. But for a programmer creating them has never been easy. Even for a few items the programmer has to create a database and other support files to create a functioning shopping cart. EasyBasket takes a different approach at creating a shopping cart; [...]
Most web security glitches are caused by insufficient input filtering and validation. Despite a large number of validation libraries being available, input sanitization is usually bypassed due to sheer laziness or the idea that your site is somehow immune from bad input data. Inspekt is one such library that has a small footprint and is [...]
One of the frequent requirements in web design is that of thumbnail generation. Although there are many libraries out there I found PHP Thumb simple and quick enough to implement in a recent project. PHP Thumb is a light-weight image manipulation library aimed at thumbnail generation. It offers the ability to resize, create custom crops, [...]
One of the most boring task for me during development is that of creating forms. I like to get the task done as quickly as possible and get on with the back-end code. There are many javascript and php libraries that enable you to do just that, but you always need to integrate the two [...]
It is surprising to see how after all the code floating around people still find it hard to create random numbers. In a recent piece of code I encountered, the following was used to generate a string of random numbers. The code was written to provide a random string to be passed to a email [...]
During a recent project, the client requested that uploaded files be encrypted for security reasons. As I already had the uploaded code ready and tested I just needed to add some extra encryption capability to the code. As earlier I’d encountered Zends wonderful Zend_Filter class, I decided to go with it and use the Zend_Filter_Encrypt [...]
debugConsole is a tool for debugging and tracing PHP5 applications on production servers without compromising the live-traffic. With PHP functions you can inspect variables, watch changes in variables over the whole runtime, measure partial runtimes, set checkpoints and write logfiles. debugConsole also replaces the PHP error-handling so that notices, warnings and other errors are also [...]