SUBMISSION FORMS

Preliminary Code

All submission forms should contain this code in the beginning of the file

Form Tag:

The attributes should be as follows
Action = "addlinkexec.asp"
Method = "POST"

The resulting Code: <FORM ACTION="addlinkexec.asp METHOD="POST">

Misc Tags

This tag will ensure the processor will redirect to this page if the page is not validated.
<input
type="hidden" name="redir" value="<%= redir %>">

This is the link type if you would like to make a submission form for atricles using display1.asp the value should be changed to 1.
<input
type="hidden" name="linktype" value="0">

HIDDEN FIELDS:

Name: required
Value:
a string of 1s and 0s specifying which form fields are required
Description: This string contains an array of six 1s or 0s and each pertains to a different field. The order is as follows: ( Title, Description, Contact Name, URL, Reciprocal URL, email address).
Example: Lets say we want to ensure everyone gives their website's title, url, and email address but we don't care about the other fields. Our string would look like this: 101100

Title Description Contact Name URL Reciprocal URL Email Address
1 0 1 1 0 1
 

The resulting Code: <input type="hidden" name="required" value="101100">

Each field also has an optional hidden field which contain the  minimum and or maximum number of characters allowed, the names are as follows:

  • titlemin
  • descmin
  • descmax
  • namemin
  • urlmin
  • recipurlmin
  • emailmin

Note: the description field also has a max field because it cannot be limited by the html code. If you would like to limit the other maximums the use this code:
<input type=text name="title" maxlength="100">

Example Title Field:

<input type=text name="title" maxlength="100">
<input type=hidden name="titlemin" value="10">

This will limit the field to be less than 100 characters but greater than 20. 

 

INPUT FIELDS:

The input fields are as follows:

  • title
  • desc
  • name
  • url
  • recipurl
  • email
  • emailopt (true/false)

ERROR MESSAGES:

The fields in the submission form can also be accompanied by error messages. The code for those is as follows:

<% if NOT (Request.Querystring("urlerm") = "") then %>
<font face="Verdana" size="1" color="#FF0000"><%= Request.Querystring("urlerm")%></font><br><% end if %>

In this example we used urlerm which is the error message for the url field. The others are:

  • titleerm
  • descerm
  • nameerm
  • urlerm
  • recipurlerm
  • emailerm

These error messages can be modified in the language/lang_submexec.htm language file.

EXAMPLE:

Lets give a full example of a complete title field.

Error Message
<% if NOT (Request.Querystring("titleerm") = "") then %>
<font face="Verdana" size="1" color="#FF0000"><%= Request.Querystring("titleerm")%></font><br><% end if %>
Input Field
<input type=text name="title" maxlength="100">
Minimum characters validation
<input type=hidden name="titlemin" value="10">