[eluser]Unknown[/eluser]
hi to all,
i'm having a bit problem i'm very new to codeigniter and i found it very interesting. i'm currently working in my login system but i'm having a difficulty dealing with it. could please someone translate this code in codeigniter terms?
Code:
<?php
if($_POST['submit']){
$select = "SELECT * FROM admin_tbl WHERE username = '".$username."' AND password = '".$password."' ";
redirect('to_page')
}else{
//FORM CODE HERE
<form method="POST" action="thisfile.php">
<input type="text" name="username" />
<input type="text" name="password" />
<input type="submit" name="submit" />
}
?>
and if the username is not equal to the data in the database table. it must redirect o the form page... even though i read the manual i still have no idea.. thanks
wish that someone can explain it too.