Hi.
How validate field max greater than field min?
I have form:
<?= Html::beginForm(['form'], 'post', ['enctype' => 'multipart/form-data', 'id' => 'form']); ?>
<h1><b>C</b></h1>
<label>min:
<?= Html::input('number', 'Min', 1900, ['min' => 1800, 'max' => 2299,]); ?>
</label>
<label>max:
<?= Html::input('number', 'Max', 2000, ['min' => 1800, 'max' => 2299,]); ?>
</label>
<h3>options</h3>
<?= Html::checkboxList('checkboxes', [0], ['1' => '1', '2' => '2']); ?>
<p>
<?= Html::submitButton('Start', ['class' => 'btn btn-primary btn-lg']); ?>
</p>
</div>
<?= Html::endForm(); ?>
Second question is ho to do it that minimum one checkbox must be checked.
I found that I can use compare but compare work when is model.
My form is html form, no model.
How to do it in Html form using Yii2?