#!/usr/bin/perl

###################################################################
#  FILE: sql_settings.cgi                                         #
#  © Copyright 2000-2005+ Seth Michael Knorr - mail@sethknorr.com #
###################################################################


	##   MYSQL RESOURCE SITES BELOW:                                         ##
	##   http://dev.mysql.com/doc/refman/5.0/en/perl.html                    ##
	##                                                                       ##
	##   To download the DBI drivers needed to run MYSQL with Perl go to:    ##
	##   http://dev.mysql.com/downloads/dbi.html                             ##


#----- M Y S Q L   C O N F I G U R A T I O N  -----#


## IMPORTANT SECURITY FEATURE: Make sure you edit the variable below.            ##
##                                                                               ##
## $SQL_encryption_key define the encryption key for the primary key used        ##
## if using the MYSQL powered success page. This feature restricts just anyone   ##
## from accessing the form results success page.                                 ##

	$SQL_encryption_key = "SQL ENCRYPT KEY";


## $SQL_db{""} is the MYSQL database where form submissions data will be sent    ##

	$SQL_db{"1"} = "DATABASE1";
	$SQL_db{"2"} = "DATABASE2";
	$SQL_db{"3"} = "DATABASE3";


## $SQL_user{""} is the MYSQL username to connect to the database                ##

	$SQL_user{"1"} = "USER1";
	$SQL_user{"2"} = "USER2";
	$SQL_user{"3"} = "USER3";


## $SQL_pass{""} is the MYSQL password to connect to the database                ##

	$SQL_pass{"1"} = "PASS1";
	$SQL_pass{"2"} = "PASS2";
	$SQL_pass{"3"} = "PASS3";


## $SQL_host{""} is the MYSQL host name to connect to MYSQL                      ##

	$SQL_host{"1"} = "host.com";
	$SQL_host{"2"} = "localhost";
	$SQL_host{"3"} = "123.12.3.44";


## $SQL_table{""} is the MYSQL table name for the associated MYSQL database that was selected     ##
## This is the table that form submissions will be sent to.                                            ##

	$SQL_table{"1"} = "sql_table1";
	$SQL_table{"2"} = "sql_table2";
	$SQL_table{"3"} = "sql_table3";


## $SQL_entries{""} are the MYSQL field names with corresponding form field names ##
## The format should be "MYSQL FIELD NAME" followed by the = sign followed by the ##
## form field name. Each set of entries should be seperated with a coma.
 
	$SQL_entries{"1"} = "sql_field=form_field,sql_field2=form_field2";
	$SQL_entries{"2"} = "first_name=firstname,last_name=lastname,email=email,phone=phone,fax=alt_phone,ip=CONFIG_ip";
	$SQL_entries{"3"} = "";



## $SQL_port is the MYSQL port used to connect to MYSQL                          ##
## Default is blank and only needs to be set if your host requires it.           ##

	$SQL_port = "";


## $SQL_replace_single allows you to specify what single quotes contained in     ##
## data written to MySQL should be converted to. If this field is left blank     ##
## single quotes will simply be replaced with a black slash.                     ##

	$SQL_replace_single = "";

## $SQL_replace_double allows you to specify what double quotes contained in     ##
## data written to MySQL should be converted to. if this field is left blank     ##
## double quotes will simply be escaped with a back slash.                       ##

	$SQL_replace_double = "";


return 1;