Password protection only hides the text, NOT the ability to purchase a ticket!!

Home Forums Ticket Products Event Tickets Plus Password protection only hides the text, NOT the ability to purchase a ticket!!

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #487899
    innovnate
    Participant

    Hi, I need urgent help here – I have password protected my events, however the password only hides the event text, not the ability to purchase a ticket. I did search through your support and found a ‘fix’ however it referred to an older version of wootickets etc as the ‘tickets.php’ no longer is used by the look of things. Is there a way to ensure the ticket purchasing section of the events pages are hidden when password protected?

    #497657
    Barry
    Member

    Hi: I’m sorry you’re hitting difficulties here.

    This should cease to be an issue in the next release of The Events Calendar … in the meantime, could you create a copy of:

    wootickets/views/wootickets/tickets.php

    And place it in:

    your-theme/tribe-events/wootickets/tickets.php

    Then locate the following line:

    <?php global $woocommerce; ?>

    Change this to:

    <?php
    global $woocommerce;
    if ( ! empty( $post->post_password ) ) return;
    ?>

    That should prevent this problem. Does that help?

    #505061
    innovnate
    Participant

    Hi, thanks for your reply! Unfortunately it actually hid all the tickets – even when logged in 🙁

    #505664
    Barry
    Member

    I do apologize, I should have caught that. Can you update that code to:

    <?php
    global $woocommerce;
    if ( ! empty( $post->post_password ) && ! wp_get_current_user()->ID ) return;
    ?>

    … Does that help?

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Password protection only hides the text, NOT the ability to purchase a ticket!!’ is closed to new replies.