if statement inside array : codeigniter
- by ahmad
Hello ,
I have this function to edit all fields that come from the form
and its works fine ..
function editRow($tableName,$id)
{
$fieldsData = $this->db->field_data($tableName);
$data = array();
foreach ($fieldsData as $key => $field)
{
$data[ $field->name ] = $this->input->post($field->name);
}…