Introduction

The verification codes feature of LinkX allow you to place images on the link, account, comment, and rating sumbission forms which will contain a word or series of characters that the user must enter in order to submit the form. This will help to reduce the number of spam submissions you receive. This document provides an overview of the verification codes feature of LinkX

Server Requirements

To use the verification codes feature your server will need to have PHP compiled with the GD extension. It is fairly common for servers to have PHP compiled with the GD extension, but if your server does not have PHP configured that way you can ask your server administrator if they will add the GD extension to PHP for you. To check if your server has the GD extension, use the phpinfo() function from the Settings menu in the LinkX control panel. This will display a large amount of information about your server's PHP installation, but you will want to look for a section like this:

If you don't see this section, it means that PHP does not have the GD extension installed. If you do see this section, you should be able to use the verification code features of LinkX.

The code.php Scripts

LinkX ships with two versions of the code.php script, one simple version that uses the built in GD fonts and a more complex version that allows you to use any True-Type Font (TTF) for the characters in the verification codes. The simple version is installed by default, so if you want to use the more advanced version follow these steps:
  1. Make sure the GD extension was compiled with FreeType support. Use the instructions in the Server Requirements section to view the output of the phpinfo() function and locate the section on GD. Look for 'FreeType Support' in that section, which should read 'enabled' if FreeType is available. If you see this, you can use the more advanced code.php script; if you don't see this you can only use the simple version.

  2. Once you know that FreeType is installed, you will need to upload some TTF fonts to your server. In the General Settings interface of the control panel you have configured a setting labeled Font Directory. You should place all of your TTF font files in this directory. Make sure you upload these files to your server in binary mode. You can find hundreds of free TTF fonts at http://www.fontfile.com/

  3. After you have uploaded some TTF files to the font directory, you will need to upload the advanced version of the code.php script to your server. This file is located in the utilities directory of the LinkX distribution. Simply upload it to the base directory of your LinkX installation, replacing the existing copy.
Using Words For Verfication Codes

By default, the verification codes generated by the software will be a random sequence of letters and numbers. If you would prefer to use regular words instead (which in most cases will be easier and less frustrating for your users) you can enter a list of words in the file named 'words' in the includes directory of your LinkX installation. LinkX ships with that file already filled with a selection of over 6500 words, but you can add to that if you wish.