Redirect to Different URL After Community Event Submission

Home Forums Calendar Products Community Events Redirect to Different URL After Community Event Submission

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #208556
    astcit
    Participant

    Hey amazing people of the modern tribe!
    (sure casey will be the guy who answers)
    ive been looking at changing my events submission form completion message, which after reading on the forms at present isnt possible;
    (https://tri.be/support/forums/topic/changing-event-submission-message/)
    so i took the other direction of doing a redirect.
    following the instructions and adding this snipet;
    https://theeventscalendar.com/redirect-to-different-url-after-community-event-submission/
    it works great. [event submission > redirects to home page]
    BUUUUUT, I want to redirect to a different page that ive created rather than the home page….
    ive tried a few different ways of putting in my custom url;
    wp_safe_redirect(page_url(/bookings/booking-completed));
    exit();
    wp_safe_redirect(url(/bookings/booking-completed));
    exit();
    wp_safe_redirect((/bookings/booking-completed));
    exit();
    none seem to allow the redirect…
    am i doing something wrong? should i be using a different trigger?
    or is what i want not possible and the redirect using this snipet will only be able to redirect to the home page?

    Thanks in advance Casey 🙂

    #209134
    Casey
    Participant

    astcit,
    You’ll need to put the entire URL there, and include it in single quotes. Something like this should work:


    wp_safe_redirect( home_url() . '/bookings/booking-completed/' );

    Give that a try. Thanks! 🙂

    -Casey-

    #215955
    astcit
    Participant

    wicked cool! thanks for that Casey!
    i couldn’t work it out for the life of me!
    appreciate your work as always mate.
    review coming soon 😉

    #216662
    Casey
    Participant

    Glad that did the trick! Since you’re all set, I’ll go ahead and close out this thread. Thanks! 🙂

    -Casey-

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Redirect to Different URL After Community Event Submission’ is closed to new replies.