[eluser]Shiju S S[/eluser]
I have a URL
http://www.quickbharat.com/frontpage/pro...Associated Consultants
This is working fine in the site.
But when I try to view it using LynxView I have a page not found error. I think it is due to the space between Associated Consultants. I have the same problem with all URL's having space. Is there any way to overcome this problem. My function is given below.
Code:
public function productdetailsview($title)
{
$title=urldecode($title);
$data['meta'] = 'QuickBharat helps promoting local businesses online and is a also a business site where visitors can search for a local business. Submitting a business helps potential customers can find your business information online by searching our business directory or when they enter search keywords in Google '; // incase limk is not avaiilable.
$query ="Select * from listeditems where title='$title'";
$result=$data['result'] = $this->sales_exe_details_db->get_results($query);
if($result)
{
foreach($result as $row)
{
$title=$row->title;
$details=$row->details;
$prdid=$data['prdid']=$row->prdid;
}
}
$data['title'] = 'quickbharat.com : '.$title;
$data['meta'] = 'Quickbharat.com '.$title.' '.$details;
$this->load->view('frontarea/header', $data);
$this->load->view('frontarea/quicksearch_box', $data);
$this->load->view('frontarea/searchbox', $data);
$this->load->view('frontarea/productdetails_view', $data);
$this->load->view('frontarea/showimage_view', $data);
// load products based on the same category and subcategory
$query ="Select * from listeditems where prdid='$prdid'";
$result = $this->sales_exe_details_db->get_results($query);
$category="";
$subcategory="";
if($result)
{
foreach($result as $row)
{
$category=$row->category;
$subcategory=$row->subcategory;
}
}
$data['category']=$subcategory; // only for showing the title
$query ="Select * from listeditems where category='$category' and subcategory='$subcategory' order by planorder";
$data['result'] = $this->sales_exe_details_db->get_results($query);
$data['category']=$subcategory; // to set the title view only
$this->load->view('frontarea/listproducts_quick_view', $data);
$this->load->view('frontarea/footer', $data);
}