php - Html tag is not working inside model attribute label in Yii2

one text

Solution:

$form->field($model, 'termsofuse')
->checkbox(['label' => Yii::t('app', 'I understand and agree to the <a href="#termsofuse">Terms of Use</a>.')])
->label(false);

More at Add encodeLabel in activeLabel #4039

Source