w3easyContact Manual

Contact Form Script

w3easyContact Manual

Postby admin » 15.12.2011 16:27

SCRIPT:
w3easyContact
(C) 2010/2011 Joachim Haack, http://w3easy.org

LICENSE
GNU General Public License, Version 3

REQUIREMENTS
PHP 5 (maybe also PHP 4 will do), NO DATABASE required.

DESCRIPTION
The w3easyContact script adds a contact form to your site. The script comes with a security check and a reload block, that prevents the repeated forwarding of a message and it has an advanced reset functionality.

INSTRUCTIONS
Installation
First unpack and then upload the script folder to your webspace.
Make sure that you have permission to edit the following files (depending on your server settings chmod the files to 0666, 0664 or 0644 if necessary):
"config.php"
"uniqid.txt"
Make sure that only you have access to the scriptfolder.
(I'd recommend htaccess directory protection using our w3easyProtect script).
Now upload the subfolder 'w3easyContact/w3eContact_css/' with the 2 files 'kontaktform.css' and 'kontaktform_ie6.css' to the layout folder of your site.

Settings
Open the "index.php" in the w3easyContact directory in your browser, check the 'show config' button, press submit and then specify the settings as it fits.

Code: Select all
<?php
$path_to_site  = "../../../"; // path to startsite
$path_to_admin = "../"; // path to general admin area
$include       = "yes"; // ("yes" or "no")
$dtd           = "html"; // ("xhtml" or "html")
$charset       = "utf-8"; // "utf-8" or "iso-8859-1" or ???
$lang          = "en"; // "en" or "de"
$max_chars     = 2000;
$adminmail     = "mail@yoursite.com"; // your email-adress
$mailsub       = "Mail to Your Site"; // email subject
$formtitle     = "Mail to Your Site"; // script title
$anchor        = "contact_anchor"; // or something else?
$form_width    = 420; // only if not included

// DO NOT EDIT, IF YOU DON'T KNOW EXACTLY WHAT YOU DO
$action        = $_SERVER['PHP_SELF']; // or what?
// $action     = "?Kontakt"; // for special cases (f.i. CMSimple)
// $action     = "http://domain.tld/contact.php";
$aufruf        = "?"; // "&"; "?";
?>

Inclusion
An easy and elegant way to include the script is to do it with the following 3 steps:

- Step 1: insert above header and edit the 2 paths respectively :
Code: Select all
<?php
ob_start();
$path_to_w3easyContact = "YOUR/PATH/TO/w3easyContact/";
$w3eContact_css_path   = "YOUR/PATH/TO/w3eContact_css/";
include($path_to_w3easyContact."contact.php");
$contact = ob_get_contents();
ob_end_clean();
?>

Note: The first path ($path_to_w3easyContact) is the path to the script folder,
the 2. path ($w3eContact_css_path) is the path to the layout folder of the script. This folder may not be located in the script folder, because of the layout files must be accessible by the user while the script folder should not be accessible.

- Step 2: insert in the head section:
Code: Select all
<?php echo $w3eContact_styles; ?>

- Step 3: insert in the body section (where the contact form shall be displayed)
Code: Select all
<?php echo $contact; ?>

Usage
After installation consider testing the script by sending a testmail...

Have fun and take it w3easy...
User avatar
admin
Administrator
 
Posts: 21
Joined: 17.03.2011 17:36

Return to w3easyContact

Who is online

Users browsing this forum: No registered users and 1 guest

cron