The regular expression, as a pattern, can match all kinds of text strings helping your application validate, compare, compute, decide etc. It can do simple or very complex string manipulations. The list of possibilities is enormous when it comes to what you can achieve using regular expressions. You can take any phrase that starts with an "A" or any character and do various things with it. You can match phone numbers, email addresses, url's, credit card numbers, social security numbers, zip codes, states, cities.....(the list never ends). A huge script that is supposed to validate a user input and prepare it for sql can be reduced to only one line with the help of preg_replace.
I have been looking online for some time to redirect http:// URL to https:// automatically. So when user request for cripperz.com it will be redirected to https://cripperz.com.
You may be thinking just exactly what is a captcha? Well you are likely to have already seen them across the web. They are those little images with a code on the front that you type into a box in order to submit something. This kind of system helps to prevent automatic submitting of an operation by some kind of program or robot. In this tutorial I will show you how to make a CAPTCHA just like the one below. Its not the most advanced captcha available because it uses a simple system font and nothing more
Joining mailing list will entitle you
to receive occasional emails informing you of news and
updates to the site and any special offers that may be
of interest to you.