View sourcecode

The following files exists in this folder. Click to view.

login.php

17 lines UTF-8 Unix (LF)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<?php
session_start
();

$checkname "user";
$checkpass "pass";
$inputname $_POST["username"];
$inputpass $_POST["password"];

if(
$checkname == $inputname && $checkpass == $inputpass){
    
$_SESSION["username"] = $checkname;
    
header("location: admin.php");
    exit();
}   else {
    
header("location: index.php?mess=Försök igen");
    exit();
}
?>