This PHP function validates an email address without using RegEx. It’s not the most comprehensive function however, as it doesn’t check for special characters that are not allowed in an email address.
Using PHPs header() function you can easily redirect to an URL of your choice by passing a simple parameter. In the below example we will redirect the user to http://www.geekpedia.com. As you can see, we pass as a parameter a string starting with “Location: ” followed by the actual URL to which we wish to redirect the […]
You normally use sessions in PHP to store information about the user’s current session that will help you track him while he is browsing your website.Sometimes you will want to destroy that session or all the sessions registered to that user, for example when he wants to log out. The easiest way of destroying all […]
Cannot modify header information – headers already sent by (output started at …) is a very popular error returned by PHP. You would receive this error if you are trying to set the header of a page after the header has already been sent to the client. There are two main ways of getting around […]
The Unix timestamp represents the time measured in seconds since the start of the Unix epoch (January 1st, 1970). The Unix timestamp is often inserted into databases, to date the records. Getting the Unix timestamp in PHP is done by using the time() function, which returns the current Unix timestamp of the server. Here we output the […]
This function returns the WhoIs string for the passed domain name (such as the domain-name owner and nameservers) by opening a socket to a WhoIs server.
If you would like to overwrite the script execution timeout limit defined in php.ini, you can do that directly from your PHP code using the following line: // Set it to no-limitset_time_limit(0); Of course you can as well set it to any time limit in seconds. The default time limit is 30 seconds.
How to backup mysql data using PHP in Windows XP, 2000, NT
Very basic hit counter based on a plain text file, built using PHP.
This PHP source code uses sockets to retrieve the URL that TinyUrl.com points to, without you having to actually access the URL.