I’ve set about upgrading my server to PHP 5.3 & faced a lot of website errors because of depreciated functions, in particular the ereg() function.
I then obviously had to go through all of the sites on the server to find the depreciated functions & I used Dreamweaver’s search by regular expression to do this, which is a quick way to find these functions. Continue reading Finding Depreciated Functions when Upgrading to PHP 5.3.x
Setting up contact forms on website can be a bit of a pain, especially if the client wants loads of custom fields, you not only have to set up the form in HTML its self but then write the fields into your sending script. With this script you won’t need to write your sendmail script over and over again. This script will simply loop through the array of posted variables to gather all of your fields, it will then format them nicely in HTML and send the data to an email addres!
Continue reading Simple PHP Contact Form With HTML Email
Captcha forms, having to type in obscure numbers and letters into a form to verify you’re a human is almost as annoying as receiving spam its self. I’ve spent some time thinking about an alternative to a captcha form that still detects if the form submission is spam without the need for users to enter an annoying code, here is the solution I’d like to share with you.
The theory is as follows; when a spam bot comes to your website, it does not see your website as regular users, nicely styled with CSS… it sees code, specifically forms, textareas and text inputs, then it fills them out and submits the form.
Continue reading Invisible Captcha Concept – Stop Spam Mail
Some of you may have seen the fancy code highlighting in my other code tutorials, this effect is achieved by using the GeSHi highlighting class.
The GeSHi library contains definitions for many script languages, a full list can be seen on their website. The default colour definitions are however not great, so I have set about customising a few of the language definitions to highlight your code as Adobe Dreamweaver CS3 would do so.
Continue reading Dreamweaver Colours for GeSHi
On this tutorial i’ll show you how to make a simple login portal using PHP for a client area of your website.
First of all you need to make a basic HTML form with a field for the username and a field for the password, these must be named ‘user’ and ‘pass’ respectively. Have this form point to your password protected page and paste the code below above the starting
<html> tag of the page.
Continue reading Simple PHP Login Script Tutorial