Support

Home Forums Event Espresso Premium EE4 – how to have no ticket selected by default

EE4 – how to have no ticket selected by default

Posted: March 22, 2015 at 12:53 pm

Viewing 5 reply threads


Ian Just

March 22, 2015 at 12:53 pm

When I go to the event’s registration page, the first sort of ticket in the list of possible tickets is selected by default.

This happens in both Firefox and Chromium.

How do I say ‘I don’t want any sort of ticket selected by default’?

If I can’t, is it possible to have a ‘non-ticket’ option in the list that doesn’t let you go to the registration page until you select something else?

EE 4.6.16.p on WP4.1.1


Dean

March 23, 2015 at 3:49 am

Hi,

When the number of tickets that can be booked in one go is set to 1, the normal drop down selection (which reverts to zero) is swapped to a Radio Button selection.

Therefore you could allow more than one ticket to be purchased at a go, which would default to 0.

If not, then unfortunately this can’t be set blank by any settings.

However, you can do it with a little bit of JavaScript added to a Site Specific Plugin (https://eventespresso.com/wiki/create-site-specific-plugin-wordpress-site/)

function remove_checked() {
    ?>

    <script type="text/javascript">
        jQuery('.ticket-selector-tbl-qty-slct').prop('checked', false);
    </script>
    
    <?php
}
add_action('wp_footer', 'remove_checked');


Ian Just

March 23, 2015 at 12:30 pm

Thanks, that works very well!

Can I suggest that having a pre-selected one is a bug?

There aren’t any pre-selected options in radio-button questions for the registration details.


Lorenzo Orlando Caum

  • Support Staff

March 23, 2015 at 1:07 pm

Hi Ian, do you have a screenshot available of the issue?

https://eventespresso.com/wiki/troubleshooting-checklist/#screenshots

I looked a sample event in the ticket selector and it doesn’t default to an option:

http://cl.ly/image/070V0q2t0n2T


Lorenzo


Ian Just

March 26, 2015 at 4:01 pm

This is when you can only book one ticket and it uses radio buttons. (I should have said in the original question, sorry.) In that case, without the script, the first one of the list of tickets is pre-selected.

If there’s only one sort of ticket, having it being selected would be fine, but it was going to be a problem for us as we’ve got 20-something types.


Lorenzo Orlando Caum

  • Support Staff

March 26, 2015 at 4:18 pm

Hi, I’m still not seeing that behavior:

http://cl.ly/image/2H1r0y3e1c0y

If the ticket is not required, then it has a default option of 0 for the quantity.

Are you running a current version of Event Espresso 4?

What are the steps for creating this type of ticket.


Lorenzo

Viewing 5 reply threads

The support post ‘EE4 – how to have no ticket selected by default’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso