it's not path error..if path error means , it won't work all the time. some times only i get the page not found error.Any way i given the code below..
Codeigniter model function for this is
PHP Code:
$title = strip_tags($barray['E_B_title']);
$description = strip_tags($barray['E_B_desc'],'<p><a><br><strong><em><li><ul><ol><img><span><font><b><i><u><strike><sup><sub><font><h3><h4><h5><h6><hr><table><tr><td><tbody><tfoot><th><thead>');
$url = $barray['E_B_url'];
$v_url = $barray['E_B_vurl'];
$javascript = '/<script[^>]*?>.*?<\/script>/si';
$noscript = '';
$remove_iframe = '/<iframe[^>]*?>.*?<\/iframe>/si';
$remove_xml = '/<xml[^>]*?>.*?<\/xml>/si';
$description = preg_replace($javascript, $noscript, $description);
$description = preg_replace($remove_iframe, $noscript, $description);
$description = preg_replace($remove_xml, $noscript, $description);
$description = rawurlencode($description);
$tags = $barray['E_B_tags'];
$date = time();
$E_post_flag = $this->session->userdata('Post_flag');
if($E_post_flag == $barray['E_add_post_flag']) {
$data = array(
'component' => 'blog',
'type' => 'posted a blog',
'title' => $title,
'description' => $description,
'u_id' => $uid,
'date' => $date,
'c_id' =>$barray['E_B_catg'],
'no_of_comments' => 0,
'url' => $url,
'place_id' => $barray['E_B_place'],
'v_url' => $v_url,
'flag' => 's'
);
//$query = $this->db->insert('enx_blogs',$data);
$query = $this->db->insert('activity',$data);
i got description from cleditor editor and then i try insert all into the activity table.some times this works well. but sometimes i got page not found error.
Bookmarks