Make "PHONE" field at Customer Registration Page - required ?

dintchev

New Member
Hello members!

Is it possible at backend? To make "PHONE" field at Customer Registration Page - required ?

Thank you very much in advance:)
 
@dintchev - create init-custom.php file in apps folder and insert this code:
PHP:
<?php

Yii::app()->hooks->addFilter('customer_model_customer_rules', function($rules){
    $rules[] = array('phone', 'required');
    return $rules;
});
 
Back
Top