"Jump to today" or "this week" in month grid view?

Home Forums Calendar Products Events Calendar PRO "Jump to today" or "this week" in month grid view?

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #117416
    Alicia
    Participant

    Is there a way to

    (a) Have a link at the top of the month grid view page that a user can click to take them to today (on the month grid view – not a separate page – basically scrolling down to the correct week for them), no matter what date ‘today’ is?

    AND/OR

    (b) When a user visits the month grid view page, the screen goes to the current week on the month grid view page?

    Our calendar has quite a few events on it and is in its early stage, so there will be many more events in the month grid view and we have found that users aren’t fond of scrolling way down to find the date they are looking for (or today) when they are looking for events on the 28th of the month, for example. If it is the 28th of the month, we’d like the screen to focus on that week, in month grid view, at least.

    I hope that makes sense. Here is the link to our month grid view so you can see what I’m referring to: http://atlantafamilycalendar.com/events/month/

    #117535
    Barry
    Member

    Hi – that sounds like an interesting idea.

    Yes I’m sure that’s possible – it is however a touch beyond what we can help you with here, however I see no reason why your link could not be dynamically generated and link to a suitable element ID (whether pinned to a table cell for a given day or the row for an entire week), something like this:

    example.com/events/#tribe-events-daynum-8

    The basic form of a snippet to make that link might be along the lines of:

    $event_url = TribeEvents::instance()->getLink( 'month' );
    $goto_today = trailingslashit( $event_url ) . '#tribe-events-daynum-' . date( 'j' );
    echo '<a href="' . $goto_today . '">Today</a>';

    That would require no particular trickery, but if you wanted to you could jazz things up with a suitable piece of Javascript to smoothly scroll the user down to that point and highlight the table cell or something of that order.

    I hope that helps 🙂

    #123329
    Barry
    Member

    This thread’s not seen much activity for the last couple of weeks so I’ll go ahead and close it. Of course if you still need help with this or any other issue please don’t hesitate to create a new thread (or threads) and one of the team will be only too happy to help. Thanks!

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘"Jump to today" or "this week" in month grid view?’ is closed to new replies.