Yii Implement checkbox check box on the same line display method, yiicheckbox_php tutorial

Source: Internet
Author: User

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 ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.