Title: Checkbox values
Last modified: August 21, 2016

---

# Checkbox values

 *  [Oshrib](https://wordpress.org/support/users/oshrib/)
 * (@oshrib)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/checkbox-values/)
 * Hi
 * How i can to set values to single checkbox? lets say “1” for checked, “0” to 
   unchecked … or true/false ?
 * I still want to use label for example:
 * [checkbox checkbox322 default:on “mark me if you want to get newsletter”]
 * But i dont want it to send “mark me if you want to get newsletter”, i want to
   get 1/0 or true/false.
 * How can i do that ?
    Thanks
 * [https://wordpress.org/plugins/contact-form-7/](https://wordpress.org/plugins/contact-form-7/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [jalbaiges](https://wordpress.org/support/users/jalbaiges/)
 * (@jalbaiges)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/checkbox-values/#post-4727017)
 * Hi Oshrib,
 * Did you ever get an answer to this question or did you get a way to solve it?
   I have the same situation.
 * Thank you!
 *  [jalbaiges](https://wordpress.org/support/users/jalbaiges/)
 * (@jalbaiges)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/checkbox-values/#post-4727018)
 * Just got a solution for select fields that can also be applied to checkboxes.
 * The idea is to add a “|<value>” (vertical separator + value to insert in database)
   inside the label text. So, if you just want to keep a “1” if checkbox is selected
   in case someone wants to subscribe to your newsletter, simply write the following
   stuff:
 * `[checkbox checkbox322 "mark me if you want to get newsletter|1"]`
 * The original info is available at [http://contactform7.com/selectable-recipient-with-pipes/](http://contactform7.com/selectable-recipient-with-pipes/)

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Checkbox values’ is closed to new replies.

 * ![](https://ps.w.org/contact-form-7/assets/icon.svg?rev=2339255)
 * [Contact Form 7](https://wordpress.org/plugins/contact-form-7/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contact-form-7/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contact-form-7/)
 * [Active Topics](https://wordpress.org/support/plugin/contact-form-7/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contact-form-7/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contact-form-7/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [jalbaiges](https://wordpress.org/support/users/jalbaiges/)
 * Last activity: [11 years, 7 months ago](https://wordpress.org/support/topic/checkbox-values/#post-4727018)
 * Status: not resolved