Home > Tips and Tricks > PHP

PHP

Tips and tricks related to PHP language

Comparing dates in PHP

167 views | PHP | No Response
Comparing dates in PHP

PHP’s date function strtotime () solves the problem of comparing dates and to check whether the user entered date/custom date is expired or not. Inorder to check whether, the custom date is expired or not, we need to do the following steps Get today’s date. Get the date to be checked. Convert the dates to [...]

Debugging PHP

248 views | PHP | No Response
Debugging PHP

Some useful techniques in debugging PHP are mentioned below Article: http://dev.piwik.org/trac/wiki/HowToSetupDevelopmentEnvironmentWindows Firefox addon – Firephp PHP Extension – Xdebug Using var_dump() <?php var_dump(__FILE__, __LINE__, $_REQUEST); ?> phpEd Zend Studio (5.5) with Zend Platform Using, print_r and echo echo “<pre>”;print_r();echo “</pre>”;

Adding watermarks to images with PHP

194 views | PHP | 1 Response
Adding watermarks to images with PHP

Watermarks play a very important role in sections of copyright and also in site promotions. But adding custom watermarks to each and every image in site using a Photo-editing software will be painful sometimes. But for regular blogging sites with more images for a single post will definitely be painful. But, adding  watermarks to images [...]