####################################################################### # SurveySays Version 1.1 # # Copyright 1998 by Matt Riffle All Rights Reserved. # # Initial Full Release: 7/4/98 This Release: 8/15/98 # # Matt Riffle's CgiScripts.Net http://www.cgiscripts.net # # Documentation File: readme.txt # ####################################################################### Table Of Contents ----------------- 1) What's New? 2) Terms And Conditions 3) How to configure this script 4) How to embed a poll on your page 5) Getting Support ----------------------------------------------------- 1) What's New? This README is for SurveySays v 1.1. Major changes since version 1.0 include: * An Optional "View Results" without voting button * The bug that caused strange behavior when two polls were embedded in the same page has been fixed. * The bug that caused a vote to be cast for the first choice if no choice was selected has been closed. * Other minor bug fixes Version 1.1 has been more extensively beta-tested than 1.0 was, and is believe to be very stable. 2) Terms And Conditions Usage of this script is subject to compliance with the terms and conditions set forth below. Your usage of this script is an acknowledgement that you have read this agreement, and that you agree to be bound by the terms and conditions below. If you do not wish to be bound by these terms and conditions, you may not use this script for any purpose whatsoever. You agree to indemnify, defend, and hold harmless Matthew P. Riffle from any and all liability, penalties, losses, damages, costs, expenses, attorneys' fees, causes of action or claims caused by or resulting indirectly from your use of this script which damages either you, Matthew P. Riffle, or any other party or parties without limitation or exception. This indemnification and hold harmless agreement extends to all issues associated with this script, including but not limited to security, and fitness for a particular purpose. This service is provided on an "as is" basis without warranties of any kind, either express or implied, including but not limited to warranties of title, noninfringement, or implied warranties of merchantability or fitness for a particular purpose. No advice or information given by Matthew Riffle shall create a warranty. Selling the code for this program without prior written consent is expressly forbidden, as is charging for the installation and/or usage of it. Obtain permission before redistributing this software over the Internet or in any other medium. In all cases copyright and header must remain intact. 3) How to configure this script There are two separate script files included in this package, poll.pl and surveysays.pl. The poll.pl file contains all the configuration variables, while surveysays.pl contains the code that does the actual "work" of the script. The poll.pl file calls the surveysays.pl file. To have multiple polls, you need only copy poll.pl for each one, and set the variables accordingly. For instance, you might have poll.pl poll2.pl poll3.pl The names aren't particularly important. Each poll can point to the same copy of surveysays.pl, so only one copy of surveysays.pl is required. Each variable is well-commented in poll.pl -- you can use the comments as guidelines helping you to set them correctly. A few further notes: a) Use full paths for all files and directories. A full path would look similar to: /usr/home/you/data.txt In UNIX, you can use the command "pwd" to get the full path of your current working directory. If you don't have telnet access or host on NT, try asking your sys admin if you are unsure of the full path. b) The following UNIX permissions are needed for the various parts chmod 755 poll.pl chmod 755 surveysays.pl In order for the script to create its data file on the first run, the directory where it should be placed (specified by you in poll.pl) should be "chmod 777". If you choose to create the file yourself (with "touch FILENAMEHERE" in UNIX), then you should "chmod 777" the file itself. If you are using NT, make sure that the poll.pl and surveysays.pl scripts are executable by the server, and that the data file can be written to by the web server. c) The extensions of the two files might need to be changed to .cgi, as in poll.cgi and surveysays.cgi. poll.pl can actual be called anything you like, maybe coolscript.pl, perhaps? 4) How to embed a poll on your page The usage of this script requires "Server Side Includes" (SSI). In a nutshell, this is a type of document that the server looks through before sending to the web browser. Any special SSI tags are processed and replaced with their output. In order to add a poll to your page, you must add the following tag to your document: If the script is set up properly, the poll should appear in place of this tag when the page is called via a web browser. Note that your tag might be slightly different, depending on the name of your poll.pl file and it's location in your web tree. On most servers, a file must have a .shtml extension (index.shtml, for example) in order to use SSI. If that doesn't seem to work, check with your sys admin to ensure you can use SSI, and to find out how to do so. If, when viewing the page through a browser, the poll doesn't appear, try checking the source code ("View Source" under the View menu in Netscape). If the SSI tag is in the source code, then the server did not treat the page as an SSI document. If it does not appear, then the server tried but was unable to execute the script. Check your variables again, and double-check all the permissions. 5) Getting Support The first line of support is the CgiScripts.Net FAQ -- located at http://www.cgiscripts.net/admin/faq.php3 -- which contains answers to a few common problems. If that doesn't help, post a message to the online Forum, located at http://www.cgiscripts.net/forum/. Please include all the information you have (including things you've tried, what happened, your variable settings). "It don't work. Why?" style messages won't get useful responses, because no useful response can be given without the proper information. Please do not send support requests via e-mail: the Forum is by far the preferred (and fastest) way to get a question answered.