Yii Implements the checkbox check box on the same line as shown in the method, Yiicheckbox
The example in this article describes the methods that Yii implements the CheckBox check box to display on the same line. Share to everyone for your reference. The implementation method is as follows:
Yii let CheckBoxList default output is a newline, a checkbox is a line, so that some settings are not required, the following we implement Yii let CheckBoxList on the same line display.
The CheckBoxList of Yii is a column, as shown in:
Someone on the internet said
Copy the code as follows: $form->checkboxlist ($model, ' like ', Array (1=> ' basketball ',2=> ' badminton ',3=> ' music '), Array (' Template ' = '{input}{label}', ' separator ' = ' + ')
This can be achieved but I find the effect is still not good, I hope you do not use this line again.
My workaround is to implement it with Yiibooster Checkboxlistinlinerow , as shown in:
It is hoped that this article is helpful to the PHP program design based on YII framework.
http://www.bkjia.com/PHPjc/920976.html www.bkjia.com true http://www.bkjia.com/PHPjc/920976.html techarticle Yii Implement the CheckBox check box on the same line as shown in the method, Yiicheckbox This article describes the methods that the Yii implementation checkbox check box displays on the same line. Share to everyone for your reference. Specific ...