Welcome Guest, Not a member yet? Register   Sign In
Form field data pulled from database
#16

[eluser]TheFuzzy0ne[/eluser]
If those are the only two fields you require, you'd be better off with a model like this:
Code:
function get_customers()
{
    /* customer selection query */
    $this->db->select('customerid, customerName');
    $this->db->order_by("customerName", "ASC");
    $res = $this->db->get('customers');
        
    return $res->result_array();
}

The above code is untested.


Messages In This Thread
Form field data pulled from database - by El Forum - 03-16-2009, 06:54 PM
Form field data pulled from database - by El Forum - 03-16-2009, 07:09 PM
Form field data pulled from database - by El Forum - 03-16-2009, 07:28 PM
Form field data pulled from database - by El Forum - 03-16-2009, 07:49 PM
Form field data pulled from database - by El Forum - 03-16-2009, 07:55 PM
Form field data pulled from database - by El Forum - 03-16-2009, 07:56 PM
Form field data pulled from database - by El Forum - 03-16-2009, 08:04 PM
Form field data pulled from database - by El Forum - 03-16-2009, 08:12 PM
Form field data pulled from database - by El Forum - 03-16-2009, 08:24 PM
Form field data pulled from database - by El Forum - 03-16-2009, 09:23 PM
Form field data pulled from database - by El Forum - 03-16-2009, 09:58 PM
Form field data pulled from database - by El Forum - 03-16-2009, 11:17 PM
Form field data pulled from database - by El Forum - 03-17-2009, 03:14 AM
Form field data pulled from database - by El Forum - 03-17-2009, 03:30 PM
Form field data pulled from database - by El Forum - 03-18-2009, 06:17 AM
Form field data pulled from database - by El Forum - 03-18-2009, 07:58 AM
Form field data pulled from database - by El Forum - 03-18-2009, 04:17 PM
Form field data pulled from database - by El Forum - 03-18-2009, 05:38 PM
Form field data pulled from database - by El Forum - 03-18-2009, 06:51 PM
Form field data pulled from database - by El Forum - 03-18-2009, 07:10 PM
Form field data pulled from database - by El Forum - 03-18-2009, 07:22 PM
Form field data pulled from database - by El Forum - 03-18-2009, 07:44 PM
Form field data pulled from database - by El Forum - 03-18-2009, 09:00 PM
Form field data pulled from database - by El Forum - 03-18-2009, 09:54 PM



Theme © iAndrew 2016 - Forum software by © MyBB