• Resolved simi7652

    (@simi7652)


    We have about 20 events a year that we need to display one at a time. the arrow should allow users to cycle five events one at a time. Currently the shortcode is displaying multiple events on the page. Your help would be appreciated.

    Here is the current code:

    <div class="event-slider grid">
      <div class="event-controls">
        <a href="index.php?page_id=113">Events</a><a id="prev-event" href="#">&and;</a><a id="next-event" href="#">&or;</a>
      </div>
      <div class="event-slides">
      <?php echo do_shortcode('[my_calendar_upcoming category="2" fallback="No events coming up!" template="0cd1df173d80fa37ac50199b1a0dd4f9" before="0" after="5" skip="0" show_today="yes" type="event" order="asc"]'); ?>
      </div>
      <div class="event-p">
      	<p>Scriptural days begin at sundown of the previous day</p>
      </div>
    </div>
    

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Joe Dolson

    (@joedolson)

    You can do that using that shortcode; use the value “1” for “after”, and you can use the ‘offset’ parameter to adjust which event.

    You can also use the single event shortcode to pick a set of specific events.

    Take a look at the shortcode arguments: https://docs.joedolson.com/my-calendar/2018/03/04/quick-start-guide/

    Thread Starter simi7652

    (@simi7652)

    Thank you Joe! I changed the after value to “1” as recommended. It did help to only show one event at a time.

    We are still unable to use the up and down navigation on the site to see the next event or previous event. See code below.

    To be honest, I am not a developer nor do I claim to understand coding. I did a search on the document that you attached and I did not see anything relating to the offset parameter.

    <div class="event-slider grid">
      <div class="event-controls">
        <a href="index.php?page_id=113">Events</a><a id="prev-event" href="#">&and;</a><a id="next-event" href="#">&or;</a>
      </div>

    Thank you for your time.

    -SC

    Plugin Author Joe Dolson

    (@joedolson)

    Sorry; it’s not called ‘offset’, it’s called ‘skip’.

    I can’t help you with the up and down navigation you’re aiming to use; that’s not part of My Calendar, and I don’t really know what you’re trying to implement.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Need shortcode to display one event at a time’ is closed to new replies.