How to turn on security code on the login and registration pages for PHP-Nuke ?

PPH-Nuke allows you to add a security code on the login and registration pages. You have probably seen the security codes when registering on online dating websites such as www.CupidPost.com. The security code is a graphic with alpha numeric letters, the user has to type the letters when registering. This prevents automated registration, without typing in the correct letters as displayed in the security code image, the submission will not be accepted.

To turn on security code you need to edit the file config.php, the file is in the root folder of your website. The variable $gfx_chk needs to be changed, for example $gfx_chk = 0; would turn off security code, $gfx_chk = 7 would trun on security code on every login and registration page. Below are the different numeric values that can be used.

0 Security code in off
1 Security code on for administrator login page only.
2 Security code on for normal user login page only.
3 Security code on for new user registrarion only.
4 Security code on for user login and registration pages.
5 Security code on for administrator and user login pages.
6 Security code on for administrator and new user registration pages.
7 Security code on for all pages.

GD extension must be installed and turned on in order for the security image to be displayed. You can check with your ISP to see if GD extension is installed. You can check yourself to see if GD extension is installed by creating a php page with the following code.

phpinfo();
?>

Save this file as phpinfo.php or name it anything you wish, such as wiivil.php, in the web server root. When you open this page with your browser you should see the php settings and status. Look for the line with GD and you should see something with GD Support enabled.

1 comment for “How to turn on security code on the login and registration pages for PHP-Nuke ?

Comments are closed.