• Resolved Ian Sterne

    (@ian-sterne)


    This plugin looks great. I have a number of websites for specific events that reoccur weekly. Events that happen every Saturday or every Friday.

    Is it possible to generate a shortcode that would display the weather for the upcoming Saturday and update automatically when Saturday is over?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Clifford Paulick

    (@cliffpaulick)

    Hi, @ian-sterne

    Glad this looks appealing to you!

    Are you using a calendar plugin, such as https://ww.wp.xz.cn/plugins/the-events-calendar/, to generate these events?

    Thread Starter Ian Sterne

    (@ian-sterne)

    For most of these sites no.

    Plugin Author Clifford Paulick

    (@cliffpaulick)

    You should be able to use PHP strtotime()

    Example: [tk_event_weather location="The White House" start_time="next Saturday America/New_York"]

    You might need to do some trial-and-error for your specific use case (e.g. what if today is Saturday?). If you’re doing this in PHP, you might want to do some PHP logic and send that result to the shortcode.

    Good luck!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Weekly event’ is closed to new replies.