WTF is wrong with this?!(other one is empty -_-;;)

Hey i was wondering if someone could tell me what is wrong with this very simple script i was writing to update my site with:


#!/usr/local/bin/perl

use strict;
use CGI qw( :standard);

$username = param('username');
$password = param('pass');

if ($username = "twoodruff") {
if ($password = "321456987") {
$news = 1;
}
}

if ($username = "jboles") {
if ($password = "mooarfbat") {
$news = 1;
}
}

if ($username = "atoren") {
if ($password = "silvermoon") {
$news = 1;
}
}

if ($news ne 1) {
print "Username/Password incorrect
";
die("");
} else {
print
Update Dryftco.org News


Date Updated:
News:
Html is allowed





#!/usr/local/bin/perl

use strict;
use CGI qw( : standard);

$news = param('news')
$date = param('date')
$author = param('user')

open(OUT, ">news") or die('Cannot find news.txt!');
print OUT "$news
";
close OUT;

open(AUTH, ">auth") or die('Cannot find auth.txt!');
print AUTH "$author
";
close AUTH;

open(DATE, ">date") or die('Cannot find date.txt!');
print DATE "$date
";
close DATE;

print
News updated successfully!


All news updated successfully

News


EOF

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories