#!/usr/bin/perl ########################################################### # - SmartStatus by SmartScript@hotmail.com # - Please leave this credit line here. # - Script Name: Status.cgi ~ Chmod: 755 # - http://www.yoursite.com/Status.cgi?pass=YOUR_PASS ########################################################### use CGI qw(param); $status = param("status"); $pass = param("pass"); $file = "Status.txt"; if ($status eq "" && $pass eq "YOUR_PASS") { &edit_status; } elsif ($status ne "" && $pass eq "YOUR_PASS") { set_status($status); } else { &loser; } sub loser { print "Content-Type: text/html\n\n"; print "Invalid Password, Lamer."; print ""; } sub edit_status { open(FILE, "$file"); $cur_stat = <FILE>; close(FILE); print "Content-Type: text/html\n\n"; print <<EOM; <html> <head> <title>SmartStatus</title> </head> <body bgcolor="050505" text="eceb9f"> <center> <br><br><br><br><br><br><br><br><br> <font size="4" color="Steelblue">SmartStatus Admin Area<b></b></font> <br><br> <form action="$0" method="POST"> <table bgcolor="eceb9f" cellspacing="1" cellpadding="1" border="0" transparency="75"> <td bgcolor="050505" align="center"> <table bgcolor="050505" cellspacing="1" cellpadding="1" border="0"> <td bgcolor="050505" align="center"> <font size="3" color="44cc55"><b> <input type="text" bgcolor="050505" border="0" usestyle width="250" nohighlight name="status" value="$cur_stat"> </font></b> </td></table> </td></table> <br><br> <input type="hidden" name="pass" value="FLaCk"> <font size="2" color="eceb9f"><b> <input type="submit" usestyle borderimage="file://rom/borders/buttonborder3.bif"> </b></font> </form> </center> </body> </html> <noembed> EOM exit; } sub set_status { open(FILE, ">$file"); print FILE "$_[0]"; close(FILE); print "Content-Type: text/html\n\n"; print <<EOM; <html> <head> <title>SmartStatus</title> </head> <body bgcolor="050505" text="eceb9f"> <br><br><br> <font size="5" color="44cc55"><b> Status Set:</b></font> <font size="5" color="Steelblue"><b>$_[0]</b></font> </body> </html> <noembed> EOM exit; }