P
P
platon20102015-02-03 16:15:51
Yii
platon2010, 2015-02-03 16:15:51

How to write Yii2 rules to validate dateDay, dateMonth, dateYear fields?

there are three <select> c <option>. dateDay, dateMonth,dateYear. How to write Yii2 rules to validate fields like

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Maxim Timofeev, 2015-02-08
@webinar

You need to create a date variable in the model and validate it, and make the rest safe.
Or write your own validator

B
bxN5, 2016-06-04
@bxN5

here is a good article on rules and scripts phpinfo.info/yii2-scenario-rules

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question