Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default value for input #19

Open
ztdan4ik opened this issue Nov 9, 2016 · 2 comments
Open

Default value for input #19

ztdan4ik opened this issue Nov 9, 2016 · 2 comments
Assignees
Labels

Comments

@ztdan4ik
Copy link

ztdan4ik commented Nov 9, 2016

Hello!
Thank you for extention. It's really helps a lot.
But now I have one issue. How to set default value for the input?
I'm using widget with ActiveForm and it writing value for the input. But it doesn't showing in field.
Look please short video of my issue http://i.de-v.net/1478693624.webm

I'll be very thankful for the help!

@Borales Borales added the bug label Nov 9, 2016
@Borales Borales self-assigned this Nov 9, 2016
@Borales
Copy link
Owner

Borales commented Nov 11, 2016

@ztdan4ik can you show me your widget code?
I've tried to reproduce this behaviour - it works correctly.

screen shot 2016-11-11 at 14 12 44

@ztdan4ik
Copy link
Author

ztdan4ik commented Nov 14, 2016

https://paste.kde.org/pgo7cxtcz

echo $form->field($user, 'telephon',[
            'options' =>
                [
                    'class' => 'form-field field-ico col-md-6 col-xs-12'
                ]
        ])->widget(\borales\extensions\phoneInput\PhoneInput::className(), [
            'jsOptions' => [
                'initialCountry' => $country['country'],
                'preferredCountries' => ['us'],
                'autoHideDialCode' => false,
                'nationalMode' => false
            ]
        ]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants