Your controller is pages/view/$1 because if you look you have no default index method.
So you need to access it like this.
PHP Code:
// wont work
$this->load->view('contact-us', $data);
// should be like this.
$this->load->view('pages/view/contact-us', $data);
If that wont work you can try this method below.
PHP Code:
// -----------------------------------------------------------------------
if ( ! function_exists('redirectBack'))
{
/**
* redirectBack ()
* -------------------------------------------------------------------
*
* Redirect back to previous page
*
*/
function redirectBack()
{
if (isset($_SERVER['HTTP_REFERER']))
{
header('Location: '.$_SERVER['HTTP_REFERER']);
}
else
{
header('Location: http://'.$_SERVER['SERVER_NAME']);
}
exit;
}
}
Place it into one of your CodeIgniter helper files.
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )