Welcome Guest, Not a member yet? Register   Sign In
Get validation rules
#11

[eluser]xwero[/eluser]
If the library isn't loaded in the controller and the rules aren't set the _field_data class variable will be empty.
#12

[eluser]pistolPete[/eluser]
And if no POST request was made, it's empty as well:

Form_validation.php
Code:
function set_rules($field, $label = '', $rules = '')
{
        // No reason to set rules if we have no POST data
        if (count($_POST) == 0)
        {
            return;
        }
(...)
#13

[eluser]xwero[/eluser]
This means loading the config file is the only solution to show the rules in the form.




Theme © iAndrew 2016 - Forum software by © MyBB