#!/usr/sww/bin/perl # ####################################################### # Power List version 1.5 # # Created by: Solution Scripts # Email: solutions@solutionscripts.com # Web: http://solutionscripts.com # ####################################################### # # # COPYRIGHT NOTICE: # # Copyright 1997-2000 Solution Scripts All Rights Reserved. # # This program is being distributed as freeware. It may be used and # modified free of charge, so long as this copyright notice, the header # above and all the footers in the program that give us credit remain # intact. Please also send us an email, and let me know # where you are using this script. # # By using this program you agree to indemnify Solution Scripts from any liability. # # Selling the code for this program without prior written consent is # expressly forbidden. Obtain permission before redistributing this # program over the Internet or in any other medium. In all cases # copyright and header must remain intact. # ###################################################### ########### YOU MUST CHANGE THE FOLLOWING ########## $name_list = "EE249: Design of Embedded Systems"; # THE NAME OF YOUR MAILING LIST $your_email = "apinto\@eecs.berkeley.edu"; # YOUR EMAIL ADDRESS # don't forget the \ before @ $your_name = "[EE249] Alessandro Pinto"; # YOUR NAME # Will show up in the from field # of all emails sent $name_url ="http://www-cad.eecs.berkeley.edu/~polis/class"; #THE URL OF YOUR SITE $name_home = "EE249"; #YOUR COMPANY OR SITE NAME $mail_prog = "/usr/lib/sendmail"; # PATH TO MAILER PROGRAM: # This has to point to your sendmail program. If your server does not # have sendmail, you may need to modify the open(MAIL,"|$mailprog -t"); # lines in all of the scripts to support whatever format your server # email system requires. If you are not sure, ask your server # administrator. If you have a virtual domain with your own root # directory, look in the /usr/sbin , /usr/lib, /usr/bin, and similar # directories, for a program named sendmail. If it does not exist, # ask your server admin what is the correct calling method. This is a # server dependent problem, and we at Solution Scripts cannot help you with # this. If you have other working scripts that send email, look at # them for clues. $remove_link = 1; # This will put a link at the bottom of all emails sent out, where a user can click on # to automatically be removed from your mailing list. Set to 1 for on, 0 for off. ################################### ## ADVANCED CONFIGURATION ## ################################### ## COLOR OPTIONS ## # The following five variables allow you to customize the look of Power List # by changing the colors of the table backgrounds and the text throughout the # Script. Simply enter the color desired, either by name or its hex number # ie: "white" or "#FFFFFF" $table_head_bg = "DARKSLATEBLUE"; # Background color of the small header row of the table $table_head_text = "white"; # Color of the text in the table header $table_body_bg = "#C0C0C0"; # Background color of the main body of the table $table_body_text = "black"; # Color of the text in the body of the table $body_tag = qq~
~; # Body tag used throughout the program. Change the body tag to however # you like. $data_path = ""; # (OPTIONAL) # Directory path to where you want the two data files stored. # EXAMPLE - $data_path = "/home/httpd/html/powerlist"; $address_file = ""; # (OPTIONAL) # Name of file where email addresses are stored. # If left blank, address.txt is used. # EXAMPLE - $address_file = "emailsaddrs.txt"; ############################################################################## # CHANGE NO MORE $version = "1.5"; $thisurl = $ENV{'SCRIPT_NAME'}; $mail_url = $ENV{'SERVER_NAME'}; $address_file = "address.txt" unless $address_file; $pwd_file = "password.txt" unless $pwd_file; $address_file = "$data_path/$address_file" if $data_path; $pwd_file = "$data_path/$pwd_file" if $data_path; read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); @pairs = split(/&/, $buffer); foreach $pair (@pairs) { ($name, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; if ($INPUT{$name}) { $INPUT{$name} = $INPUT{$name}.",".$value; } else { $INPUT{$name} = $value; } } unless ($INPUT{'email'}) { print "Content-type: text/html \n\n"; &Top; } $temp=0; $temp=$ENV{'QUERY_STRING'}; if ($temp) { $INPUT{'address'} = $temp; &remove; } if ($INPUT{'email'}) { &email; } elsif ($INPUT{'action'} eq "subscribe") { &subscribe; } elsif ($INPUT{'action'} eq "remove") { &remove; } elsif ($INPUT{'newpass'}) { &newpass; } elsif ($INPUT{'delete_select'}) { &delete_select; } elsif ($INPUT{'delete_final'}) { &delete_final; } elsif ($INPUT{'sendemail'}) { &sendemail; } elsif ($INPUT{'address'}) { &subscribe; } else { &admin; } exit; ########### MAIN ADMIN SCREEN ########## sub admin { open (PASSWORD, "$pwd_file"); $password =Set Admin Password |
Before you can do anything else, you'll need to set your administrative password. This will allow you to use the administrative functions, Please enter your desired password below. (Enter it twice.) |