Saturday, July 4th, 2009

Archive for September, 2008

How to remove a (non-empty) directory

This is a snippet that removes a non-empty directory from the server. It’s a recursive function that deletes the directory and all its contents (files, folders and sub-folders).

Read more

Resize an image (on the fly) & keep its aspect ratio using GD

This is a PHP Class useful if you need to resize images keeping their aspect ratio, using the GD Library.

Read more

How to convert smilies to graphics

This is a function that modifies a text (comment) by converting the emoticons like :) , :D , (Y) etc. to graphic icons.

Read more

How to validate a telephone number

This snippet is useful if you need to validate a telephone number using an editable list with specific formats.

Read more

How to use an image as a submit button

Tired of using the classical submit buttons? Replace them with images.

Read more

Check (validate) if the uploaded file is an image

This script checks if the uploaded file (via a form) is actually an image. You can choose between 2 validators: one that will check if the file is actually an image and the other one which checks the extension of the uploaded file.

Read more

Calculate the size, number of files & folders of a directory

This is a PHP Class that calculates the size, number of files & folders of a specific directory.

Read more

How to add a stylish icon into a (form) text box

This CSS Code is useful if you need to add a stylish icon into a text box inside a form.

Read more

Creating stylish pagination links

Do you want to add some style to your pagination links?

Read more

Show random image(s) from a directory

This script is useful if you need to randomly select images from a directory.

Read more

How to select a random value from an array using a specified range

This function selects randomly a value from an arrray using a specified range.

Read more

How to make a download script without disclosing the location of the files

In this tutorial you will learn how to create download links which do not disclose the actual location of the files.

Read more

Creating a simple web data (spider) extractor

This is a simple tutorial about creating a simple web data extractor that will fetch specific content from a URL.

Read more

A tableless 3 (fluid) columns layout

This is a simple tableless layout that uses DIVs having 3 (fluid) columns, a header & a footer.

Read more

Equivalent of PHP’s in_array() function

This is a JavaScript function that works like in_array() in PHP.

Read more