Default value

This topic contains 2 replies, has 2 voices, and was last updated by  Stephen Harris 12 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • #33826

    With out default value in fields, this plugin no useful for my project. Please add this in update.

    Dmitri Nepo

    i finding solution to set default value to all input fields

    value=”<?php echo esc_attr( $this->get_value() );?>”
    value=”MY VALUE”

    in file “eo-event-form-input”

    Dmitri Nepo

    You can do this in code:

    add_action( 'eventorganiser_get_fes_form', function( $form ) {
            $form->get_element($element_id)->set_value('MY VALUE');
    }, 1 );

    where $element_id' is the ID of the form element. If you hard-code the value in the template then you will have the same value for all fields using that template. Additionally it would produce some unintended results when editing events from the front-end, if that is enabled.

    Stephen Harris
Viewing 3 posts - 1 through 3 (of 3 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.