Welcome Guest, Not a member yet? Register   Sign In
Can not use localization on form validation rules
#1

We have a set of rules like below:

PHP Code:
public $rules = array(
 
'login'=>array(
 
'email' => array(
 
'field' => 'email',
 
'label' => 'Email',
 
'rules' => 'trim|valid_email|required'
 
), 

where we would like to replace the 'label' => 'Email' with $this->lang->line('user_email')

However it produces the following error:

Message: Constant expression contains invalid operations

Are we doing something wrong?
Reply


Messages In This Thread
Can not use localization on form validation rules - by edoramedia - 11-21-2019, 09:45 AM



Theme © iAndrew 2016 - Forum software by © MyBB