Welcome Guest, Not a member yet? Register   Sign In
$_GET and form inconsistancies -- suggestion to engineers.
#1

[eluser]Jaketoolson[/eluser]
I'm using $_GET for the majority of my forms and have had no problems with this using CI 2.0. In form_helpers and other places, you only check for $_POST and never for $_GET. I understand this is an obvious observation, but since you've enabled query_string and $_GET support, it would be nice if you could quickly enable this throughout all methods and functions.

for example, currently I can't use set_value() in any of my forms :
Code:
function set_value($field = '', $default = '')
    {
        if (FALSE === ($OBJ =& _get_validation_object()))
        {
            if ( ! isset($_POST[$field]))
            {
                return $default;
            }

            return form_prep($_POST[$field], $field);
        }

        return form_prep($OBJ->set_value($field, $default), $field);
    }

Also, the form helper functions are inconsistent. For example, form_dropdown() and form_hidden() functions do not allow me to pass an array of 'extra parameters' yet the other form helper functions do...

For now, I'll have to extend all functions where this occurs just thought it would be nice to consider updating.


Messages In This Thread
$_GET and form inconsistancies -- suggestion to engineers. - by El Forum - 02-28-2011, 01:44 PM



Theme © iAndrew 2016 - Forum software by © MyBB