How to bind Yii2 HTML forms dynamically for validation?

Rather than retype entire Q, here’s the SO post:

really appreciate any help

g