Making default fields mandatory in booking form

WordPress Event Management, Calendars & Registration Forums Pre Sales Questions Making default fields mandatory in booking form

This topic contains 2 replies, has 2 voices, and was last updated by  Sue 9 years, 11 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #15069 Reply

    Sorry, I know this is the wrong forum, but my subscription has expired (I’ve come from the WP forums).

    I’m using Pro 1.6.3. plus 2.11.1

    I’m trying to add tickets to an event. By default, it gives me first & last names and email. However, only first name and email are mandatory. How can I make the last name mandatory, or better yet, turn off those fields and add my own advanced fields instead?

    Sue
    #15077 Reply

    Hi Sue,

    Sorry to make you cross post 🙂

    In 1.6.3 it isn’t possible. It is in 1.9.5 (and presumably 1.9.* I’ve not checked) with the following code

     add_action( 'eventorganiser_get_event_booking_form', 'booking_form_require_last_name', 10, 2 );
     function booking_form_require_last_name( $form, $event_id ){
    
         $name = $form->get_element( "name" );
         $name->set( 'lname_required', true );
    
     }
    

    and in 2.10.0 there’ll be a UI option for this.

    Stephen Harris
    #15083 Reply

    Thanks Stephen. I’ll have to work around it.

    cheers,

    Sue
Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: Making default fields mandatory in booking form
Your information:




To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax


<a href="" title="" rel=""> <blockquote cite=""> <code> <pre> <em> <strong> <del datetime=""> <ul> <ol start=""> <li> <img src="" border="" alt="" height="" width=""> <p style=""> <span style="">