Jump to content

how to group checkbox ?


adrianmak
 Share

Recommended Posts

I found that, the way to create checkbox option in pw is different than Drupal I was used.

In Drupal, checkbox options are defined in field settings.

In PW, a checkbox field type in an option of checkbox.

In order to create a field with three checkbox, admin should create three fields which are field type of checkbox.

Then, how to group them into a field ?

For example,  to create payment method with three checkbox option, paypal, COD, paydollar

Link to comment
Share on other sites

Either use a Page field or the new Options Fieldtype and then choose the Checkboxes Inputfield.

Checkboxes as an Inputfield is very different to the singular "Checkbox" fieldtype.

I could see "Checkbox" in field type only. This is what I said in OP, it is a single checkbox

post-2272-0-58730300-1429922331_thumb.pn

Link to comment
Share on other sites

What Adrian said is right and this Q has been asked a lot of times.

You need to first create a field, not of type checkbox. you need to use options field or page field.

then you will be able to select checkboxes as the input field to select those options or pages.

  • Like 1
Link to comment
Share on other sites

your first sentence is arguable. For years we have all used page fields for selects, radios, group checkboxes. it's part of what you need to do, and once you know how to do it fast and easy, then you just do it and don't get caught up in that sort of "too much for simple case" mindset; it just works.

nevertheless, Ryan introduced the options fieldtype for when you want to avoid the page field:

http://lmgtfy.com/?q=processwire+fieldtype+options

the first 3 results should explain it all.

  • Like 3
Link to comment
Share on other sites

options fieldtype available for 2.5.17+

it is dev version, stable for production siite ?

The dev branch is generally very stable, and can be used in production sites. That said, I suggest you have a look at this thread for more information.

However, as Martijn has posted, we are very close to the 2.6 release, which implies that 2.5.28 is stable.

I am using the dev branch on all the sites I'm building right now.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...