(newbie) Forms - email management & flat file databases
I need to create an opt-in form with various check boxes and text fields that can be submitted to an email to me as well as some sort of a database.
I need to be able to use the database to manage the email list.
100 people filled out the form on this date.
20 people checked a box indicating that want more information on widgets
60 people want mote info on do-dads
20 people want more info on both products
75 people were new customers
25 were return customers
10 were from California
2 from Texas
I would like to be able to use the database to analyze the various aspects of the data collected as well as quickly do things like send a mass email to everyone who is a return customer from California and wants more info about our do-dads.
I’m not a programmer or database administrator, just a graphic designer.
I’ve made several simple forms using Mat Wrights FormMail and I have no experience with databases other than the most basic understanding of what flat file and rational databases are.
Description: Appends field values to a flat-file database.
If you wish to append the form fields to a flat file database, just specify the filename as the value of this field. The value should specify the path and file to hold the data.
When using the append to database feature, the initial blank datafile MUST be created on the server prior to using the script. The script does not automatically create it; it only appends to it! (Very common mistake) In addition, the data file AND the directory containing it MUST have world write permissions. If you do not understand Unix permissions, please ask your system administrator for help. The permission for the directory holding the data files must have world write access since the server does not have any special privs. On my system, world execute access is also required, so the protection should be 773 (rwx, rwx, wx). As for the data file itself, remember it must be created first, manually. Use any editor to create an empty file. If you don't understand empty, create a file with the letter "A" in it, then delete the "A" and resave it! The file MUST have world write permissions for the same reason as above. Use 662 (rwx, rwx, w).
When specifying the datafile itself in the form field, it can be either a full unix path, e.g. "/home/users/smith/public_html/cgi-bin/data/datafile.dat" or a relative path, e.g. "./data/datafile.dat". It is important to note that if you specify a relative path, it is usually the path relative from the CGI-BIN directory. Do not specify the CGI-BIN as the location of the data file since most servers do not allow write access to this directory. You CANNOT specify a URL such as "http://www.myserver.com/cgi-bin/data.dat".