query($sql) or die ($mysqli->error); header('Location: index.php'); } $nis = $_GET['nis']; if (empty($nis)) header('Location: index.php'); $sql = "SELECT * FROM siswa WHERE nis = '$nis' "; $query = $mysqli->query($sql); $siswa = $query->fetch_array(); if (empty($siswa)) header('Location: index.php'); include 'views/v_tambah.php'; ?>