######################################################################
#################  Mail List Plugin  version 1.01 ####################
######################################################################                        
# Mail List Plugin for perlshop.cgi                                  #
# Author : Chris Jacobs.(aka Jack)                                   # 
#          (email: Jack@sarune, chris_jacobs_nj@yahoo.com)           #
#                                                                    #
# I created this Mail List script from a script available on the net #
# I simply changed it to work as a plugin to use with the free       #
#                 shopping cart program PERLSHOP.CGI                 #
#                The latest version is available from                #
#                       waveridersystems.com                         #
#                                                                    #
#           WORKING DEMO  @ www.sarune.com/Sarunatic/                #
#           DEMO of admin www.sarune.com/cgi-bin/madmin.pl           #
#                                                                    #
######################################################################
# Revision History                                                   #
######################################################################
# Version 1.01                                                       #
# - added ability for perlshop to call this plugin on checkout       #
#   which adds the email from the order to the list.                 #
# - The param order has changed from V1.0 to allow for checkout call #
#                                                                    #
######################################################################
#                                                                    #
# I have tried to document the script for changing the variables     #
# that will need to be changed. Any suggestions, comments, questions #
# for improving the script or this ReadME file please send me eMail  #
#                          jack@sarune.com                           #   
#                                or                                  #
#                      chris_jacobs_nj@yahoo.com                     #
#                and I will do my best to help out                   #
#                          Thank you, Jack                           #
#                                                                    #
#                                                                    #
######################################################################
                                                                     #
This plugin allows your users to add or remove their email           #
from a mailing list.     maillist.cgi is the plugin script.          #
                                                                     #
Also included is mail-admin.pl which is a simple admin script for    #
making up an email that is sent to all your subscribers.             #
                                                                     #
######################################################################

Simple Installation Instruction(addition info is in the 2 scripts):

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!  NOTE: PLUGIN_PARAM ORDER MATTERS, IT HAS CHANGED SINCE V1.0 !!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

1) If the path to perl on your server is different from 
   #!/usr/local/bin/perl then you will need to change it on the first line in each script.
   (maillist.cgi and mail-admin.pl) 

2) Upload maillist.cgi & mail-admin.pl scripts to your cgi-bin 
   then chmod them to "755."

3) Modify the header and footer files with a text editor. 
   The files header.txt and footer.txt will be inserted into 
   the email message.
   
4) Modify the pheader.txt and pfooter.txt files.
   These are HTML and will be used to build the page returned
   from the script. A message is placed in between for 
   success or failure of the email add or subtract.

5) Upload header.txt, footer.txt, pheader.txt, and pfooter.txt 
   to the directory you specify in the scripts. 

6) Upload pass.dat and list.txt the directory you specify in the scripts. 
   Leave pass.dat blank. It will be used my the mail-admin.pl
   list.txt is for the emails.

7) Execute the admin script (mail-admin.pl) with your browser (Point the url to main-admin.pl). 
   The script will ask you to set up your admin password and You'll be set to go.. 

8) Enclosed is an html document with an example form for
   calling the maillist script.

9) Dont forget to add maillist.cgi to ps.cfg as a plugin.
   
Example plugin registration table before adding the Mailing List plugin:
# Plugin modules.  See the external documentation for details.
%plugins =
(
	# Calendar example plugin
	'calendar'  => 
	{
		'program'	=> 'gencal.pl'
	}
);


Example plugin registration table after adding the Mailing List plugin:
# Plugin modules.  See the external documentation for details.
%plugins =
(
	# Calendar example plugin
	'calendar'		=> 
	{
		'program'	=> 	'ps_plugin_gencal.pl'
	},

	# Mailing List plugin
	'mailing_list'	=>
	{
		'program'       => 'maillist.cgi',
		'event'	=>	'after_place_order'  # <--Omit this line if you dont want 
	},                                           #    the plugin called at checkout
);


!!Important!!
upload everything in "ASCII" mode
