i have applied tags functionality in my project just like stack overflow.
When i subit multiple tags from my form, and in my controller i am getting it like this:
$this->input->post('tags_id') so i am getting 2,3,44,442 as the value for $this->input->post('tags_id') altogether.
What i want is i want the each value to be inserted into my tags table one by one.
How can i get the each value from from the comma separated list to be inserted in my db? Please help me...
I am doing the following to insert into my db
function entry_insert_instdetails()
{
$this->load->database();
$this->db->trans_begin();
$data=array('instrunction'=> $this->input->post('tags_id'),
'creater_id'=>$this->session->userdata('userid'),
);
$this->db->insert('instructions',$data);
if ($this->db->trans_status() === FALSE)
{
$this->db->trans_rollback();
}
else
{
$this->db->trans_commit();
}
}