Welcome Guest, Not a member yet? Register   Sign In
Issue with database record updating: updating record inside a foreach loop?
#7

[eluser]Salvatore Formisano[/eluser]
[quote author="saidai jagan" date="1260983116"]hai u can directly giv like this ?
Code:
$this->m__crud->update_record("photos",$key,$value);
[/quote]

Hi there,

yes I can, as you can see I am referencing a model, here's the update_record method of that model:

Code:
function update_record($table,$id,$data)
{
$this->db->where('id',$id);
$this->db->update($table,$data);
}


Messages In This Thread
Issue with database record updating: updating record inside a foreach loop? - by El Forum - 12-16-2009, 05:12 AM



Theme © iAndrew 2016 - Forum software by © MyBB