Problem with moving the events page title

Home Forums Calendar Products Events Calendar PRO Problem with moving the events page title

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1304759
    David
    Participant

    I tried to move

    <?php echo tribe_get_events_title() ?>

    outside the content.php template to another part of the page, but when the page reloads trough ajax the title doesn’t update anymore.

    Do you have any suggestion on how to call ajax or about any other intervention to solve this?

    Thank you,
    David

    #1310122
    Barry
    Member

    Hi David,

    That’s a great question!

    By design, rather than fetching the entire page, we just grab the contents of the #tribe-events-content div. There are a few ways you might workaround this.

    The important thing of course is that you communicate the desired title in the ajax responses. You could do this by additionally including the events title in a hidden element, or as a data attribute for an existing element. Alternatively, you could include it in the response data by utilizing the tribe_events_ajax_response filter hook.

    Client/browser-side, some Javascript could be setup to listen for successful ajax responses (the ajax-success.tribe event will be triggered) which can then grab that fresh title and use it to overwrite the content of your desired title element.

    Does that make sense? Unfortunately we cannot go into too much detail with custom dev questions like this one, but I hope that at least gives you a strategy you can explore further 🙂

    #1323892
    Support Droid
    Keymaster

    Hey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.

    Thanks so much!
    The Events Calendar Support Team

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Problem with moving the events page title’ is closed to new replies.