Welcome Guest, Not a member yet? Register   Sign In
Advice or help accessing object items.
#2

Once you get the posted value, how do you save it if you don't know the name of the dropdown element in your form?
The selected value in a dropdown belongs to the name of the <select> ... </select> stucture.
This part needs some more explanation, please also share the code of your view.

Besides that, your function translateDropDown can be a lot shorter:
PHP Code:
public function translateDropDown($type$id){  

        
$table 'fx_categorycomponents' $type;
        
$this->db->select($type);
        
$this->db->from($table);
        
$this->db->where('id'$id);
        
$this->db->order_by($type'asc');
        
$query=$this->db->get();
        return 
$query;    
        
    }
//end translateDropDown 
Reply


Messages In This Thread
RE: Advice or help accessing object items. - by Wouter60 - 03-18-2016, 06:27 AM



Theme © iAndrew 2016 - Forum software by © MyBB