• Resolved pstidsen

    (@pstidsen)


    Hi there,

    I am struggling with making a dynamic top bar text on my website. I want to give the most relevant and accurate information in one line. Right now I have: [open_text]%if_not_open_later% The farm store is closed %if_open_tomorrow% , but open again tomorrow at %hours_tomorrow%. %end% %else% %if_open_today% The farm store is open today %hours_today% %end% %end%[/open_text]

    However, if the farm store is not open before the day after tomorrow (when happens on Saturday, when they are not open before Monday), the text is just “The farm store is closed”. How can I add “, but we are open again Monday at XX:XX” where Monday and the time is dynamic. Is it possible or would you consider adding a “next day open” and “next dat open hour”-shortcode.

    I do hope my quesiton makes sense.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter pstidsen

    (@pstidsen)

    I have got an answer from the support via e-mail who encouraged me to post the question here as well. The answer is as follows:

    Thanks for this question, it’s really good and would be really well-placed in the public forum for others to see.

    Unfortunately, there is nothing to scan ahead a few days to the next opening time. At the moment it will just check for today and tomorrow in the conditional text – so if the shop is closed tomorrow, yet open on Monday, you’ll need to write this in manually (if there’s only one day its closed) for the moment. I recommend having something like “We’re open again after the weekend” (perhaps including the time within the text).

    I will be extending the conditional text bit by bit, depending on demand and how easy it is to introduce. The code here is actually complex because it involves very large IF statements and tracking of each introduction of a condition.

    I will keep your example in mind and if I can think of a good way to check ahead and pick the day name and the opening time, add this as a replacement work and something to handle this as a condition (e.g. %if_open_within_week%). Everything I introduce needs to be easy for people to grasp and its name obvious as to its purpose. And, for each “positive” I need to include the “negative” version.

    Thanks again and feel free to post this on the forum if you feel inclined.

    Best regards,
    Noah Hearle

    Plugin Author Design Extreme

    (@designextreme)

    Thanks @pstidsen! This is very helpful.

    I’ll keep your example in mind when extending the conditional text.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Open After Two Or More Days’ is closed to new replies.