WordPress.org

Ready to get started?Download WordPress

Forums

Events Manager
[resolved] Booking spaces no default and default number to unlimited (11 posts)

  1. snatrott
    Member
    Posted 2 years ago #

    I am using Events Manager version 5.0.51. I have heavily modified many of the templates regarding adding events and booking options. I have Single ticket mode set to Yes. I assumed that would make the Spaces drop down disappear as I want the default and only option to booking 1 ticket. How can I force the drop down to disappear and the form default to 1 ticket?

    Additionally, I want each event to have unlimited spaces available. I read that a number has to be used and the default is 10. I would like to set the default to 1,000,000 for every event. Where can I change the default number?

    Lastly, I need to know what file contains the code for the Book Now button.

    Thanks so much for all of your help!

    http://wordpress.org/extend/plugins/events-manager/

  2. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 2 years ago #

    if you set a minimum/max of 1 ticket in the ticket settings, it should hide the ticket if you have one ticket showing without the tickets table.

    I think this is done in the templates, e.g. templates/forms/event/bookings.php

    the book now button is in templates/placeholders/

  3. snatrott
    Member
    Posted 2 years ago #

    I fixed the Book Now button. Thank you so much!!

    In the template: templates/forms/event/bookings.php, I played around with adding the min/max of 1 but none of my changes worked. I thought I could put the 1 in place of the dashes here:

    <td class="ticket-limit">
    								<span class="ticket_min">
    									<?php  echo ( !empty($EM_Ticket->ticket_min) ) ? $EM_Ticket->ticket_min:'1'; ?> <!--changed the dash to a 1 in this line-->
    								</span> /
    								<span class="ticket_max"><?php echo ( !empty($EM_Ticket->ticket_max) ) ? $EM_Ticket->ticket_max:'-'; ?></span>
    							</td>

    That had no effect on the drop down list.

    And where can I change the default spaces from 10 to 1,000,000?

  4. snatrott
    Member
    Posted 2 years ago #

    I set the default values in the database, and that seems to work for the moment.

  5. saijin_nxtoyou
    Member
    Posted 2 years ago #

    To change the Event Manager >> Available ticket spaces value, go to wp-content/plugins/events-manager/classes/em-ticket.php

    change:
    var $ticket_spaces = 10;
    to:
    var $ticket_spaces = 1,000,000;

  6. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 2 years ago #

    thx for the input.

    better yet, if you don't want to hack, hook into the em_ticket action and modify it that way. e.g.

    function my_spaces_function($EM_Ticket){
    $EM_Ticket->ticket_spaces = 1,000,000;
    }
    add_action('em_ticket', 'my_spaces_function',10,1);

  7. Bayu Widyasanyata
    Member
    Posted 2 years ago #

    Hi Marcus,

    I just upgraded to 5.1.8.1 and having problem with availability space on booking system. It's whenever I put the number, i.e. 50 spaces, the availability space is always to default number 10.

    Shown on Event Bookings page:
    Availability : 1/10 Spaces confirmed

    And the "Total Space" field on the Booking/Registraion box always reset to 0 (zero) when I try to edit the event.

    How to fix that?

  8. agelonwl
    Member
    Posted 2 years ago #

  9. chrishylton2012
    Member
    Posted 2 years ago #

    Putting commas in the ticket_spaces (1,000,000 vs 1000000) breaks my entire site (turns everything into a blank screen). I have to do it without commas. Just incase anyone has this issue and is puzzled.

  10. Marcus
    NetWebLogic Support
    Plugin Author

    Posted 2 years ago #

    noted that down, will fix asap

  11. Tech4Eleven
    Member
    Posted 2 years ago #

    How can I force the drop down to disappear and the form default to 1 ticket?

    snatrott, I am trying to do just that exact thing but I cant make it work. Did you find a solution and can you tell me how?

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic