Checkbox Checked by Default

Support General Checkbox Checked by DefaultResolved

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #13060
    Max@powdersky.com[email protected]
    Participant

    Hi,

    Currently want to have a checkbox checked by default but it doesn't seem to be working:

             array(
                'name'  => 'New Property?',
                'id'    => self::$prefix . 'new_property',
                'type'  => 'checkbox',
                'std'   => 1,
            ),

    Thanks

    #13075
    Anh TranAnh Tran
    Keymaster

    Hi Max,

    Does it work with new posts?

    The mechanism of std in Meta Box works only if the meta box has not been saved before. Here 'meta box' means all fields. So if there's any field that already has value, then std won't work for other fields, even new fields you've just added.

    #13089
    Max@powdersky.com[email protected]
    Participant

    Thanks Anh, that would be it!

    Shows on a new property so all fine, thanks.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.