[eluser]Unknown[/eluser]
I found the video tutorial of login and worked according to that, following code area where I worked out but still I getting Error 404 .
I try to flowing code also
<?php echo form_open(base_url(). 'usertest/test' ) ?>
/* i used following code also to place of above line */
<?php echo form_open('usertest/test' ) ?>
I am using 2.0.2 ver of CI.
****************************************************************************************
// Base url
$config['base_url'] = 'http://localhost/ci/';
****************************************************************************************
//config file
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Usertest extends CI_Controller {
public function index()
{
$this->load->view('view_login');
}
public function test()
{
echo 'Look at this!';
}
}
****************************************************************************************
//view_login.php
//Body Part
<Table cellspacing="5" cellpadding="3" border="0" align="center" style="background-color:#CCCCFF; border
olid 1px #CC99FF;" id="login_form">
<?php echo form_open(base_url(). 'user/test' ) ?>
/* i used following code also to place of above line */
<?php echo form_open('usertest/test' ) ?>
<tr>
<td>User Name </td>
<td>:</td>
<td><?php echo form_input(array('id'=>'username', 'name'=>'username'));?></td>
</tr>
<tr>
<td>Password </td>
<td>:</td>
<td><?php echo form_password(array('id'=>'password', 'name'=>'password'));?></td>
</tr>
<tr>
<td></td>
<td></td>
<td><?php echo form_submit(array('name'=>'submit'), 'Login');?></td>
</tr>
<?php echo form_close(); ?>
</table>
****************************************************************************************
// when i execute this script show following error
Not Found
The requested URL /ci/user/test was not found on this server.