bli eliy..
q mw nanyak lagi...
klu kode loginnya tidak menggunakan session gmn...?
ini saya sertakan kodingnya:
<?
ob_start();
include "include/koneksi.php";
$un=$_POST['un'];
$pw=$_POST['pw'];
$go=$_POST['go'];
$type=$_COOKIE['type'];
$sel=$_GET['sel'];
$query="SELECT password,type FROM user WHERE username='".$un."';";
$hasil=mysql_query($query,$con);
$password=mysql_fetch_array($hasil);
$ty=$password[1];
if ($un&&$go){
if ($password[0]==$pw){
$expire=time()+3600;
setcookie("user",$un, $expire);
setcookie("log", true, $expire);
setcookie("type",$ty, $expire);
header('Refresh: 0.2; URL=index.php');
}
}
$p=$_GET['p'];
?>