NAK
NAMA : JUMADI
NIM : 181011450216
Banten 15310
SESI – 1
PENDAHULUAN
RANCANGAN APLIKASI
2.1 USE CASE DIAGRAM
PENGUJIAN (TESTING)
8
9
- Login Errot Not email caracter username - Login Succes with email caracter username
10
- Submit Errot semua kolom wajib disi - Login Succes semua kolom terisi
1. <?php
require 'functionkormi.php';
2. //cek login terdaptar
if(isset($_POST['login'])){
$email = $_POST['email'];
$password = $_POST['password'];
3. //cocokin dng database,
$cekdatabase = mysqli_query($conn, "SELECT * FROM login
where email='$email' and password='$password'");
4. //hitung jumlah database
$hitung = mysqli_num_rows($cekdatabase);
if($hitung>0){
$_SESSION['log'] = 'True';
5. header('location:indexkormi.php');
} else {
6. header('location:loginkormi.php');
};
};
7. if(!isset($_SESSION['log'])){
} else {
8. header('location:indexkormi.php');
}
9. ?>
12