.htaccess file is a magic file. You can change the way your website works by using it. I have been reading a lot about .htaccess files. Perticularly .htaccess is very useful in shared web hosting environment where the users have no direct access to their servers or they want to implement some restrictions/security to their [...]

{ read more }

If you have to create a date object of future or past, you can do it by using the second parameter of PHP date function. This is extremely useful when doing BETWEEN comparison in MySQL. You can build the date and bind it to query.

{ read more }

by Hiroshi on September 30th, 2008

With this PHP script you can find size and type (extension) of required file.

{ read more }

By default there is a restriction of 2 Megabytes file upload at a time for PHP. If we have to upload media files or other large files then we will have to change some settings in php.ini. Locate the php.ini file in the folder your upload script resides in. If none exists, install a new [...]

{ read more }

by Hiroshi on August 7th, 2008

I think there is no way yet to find out screen resolution with PHP. hehehe. If I am wrong please correct me. But yet we can trick it to be happen ;-) If not then how can we be developers. Right! With javascript we find out screen resolution of PC. Store it in a cookie [...]

{ read more }

String to Upper Case – strtoupper The strtoupper function takes one argument, the string you want converted to upper case and returns the converted string. Only letters of the alphabet are changed, numbers will remain the same.

{ read more }

by Hiroshi on June 19th, 2008

Use this example to show some hidden message at page using PHP. You can use two pages for that or single page if register_globals are on in your php.ini settings.

{ read more }