• Resolved erwinteering

    (@erwinteering)


    Hi Noah,

    Thanks for the quick response!

    I would like to have three separate notifications per day:

    Before opening: Carwash Uden opens at …

    During opening: Carwash Uden is open until …

    After opening: Carwash Uden opens again tommorw from …
    (and when it is closed tomorrow: Carwash Uden is closed tomorrow)

    Thanks in advance!

    Sincerely,

    Erwin Teering

    Hi Erwin,

    Thanks for getting in touch.

    Here is your question:

    A small question, I am using the shortcode below. Is it possible to indicate that when it is (for example) 8 o’clock and the location opens at 10 o’clock he indicates that it will open at 10 o’clock, without indicating that it will be open again from 10 o’clock tomorrow?

    Now he shows both. I would like to see one before opening, and the other after opening on that day

    Is this due to the order of shortcodes or is there not (yet) a code for this? If not, can it be made?

    You posted me the following shortcode and content:

    [open_text]
    
    %if_open% Carwash Uden is open today until %today_end% %end%
    
    %if_closed%
    
    %if_open_today% Carwash Uden opens today at %today_start% %end%
    
    %if_open_tomorrow% Carwash Uden is open again tomorrow from %tomorrow_start% %end%
    
    %if_closed_tomorrow% Carwash Uden is closed tomorrow %end%  
    
    %end%
    
    [/open_text]

    Note: I presume you are removing the line breaks so the sentence works? I am keeping them here for clarity. I have also indented the logic to show it more clearly.

    If you only want to show that it is open today at a certain time, you only need to cut out the references to tomorrow. This would look something like:

    [open_text]
    
    %if_open% Carwash Uden is open today until %today_end% %end%
    
    %if_closed%
    
    %if_open_today% Carwash Uden opens today at %today_start% %end%
    
    [/open_text]

    The ordering of the replacement logic is not important if the two bits of logic are mutually exclusive. Please ensure that you open and then close each logic statement properly.

    Is that what you meant by your question?

    Please can you post something on the forum if you feel it is relevant to other people – it is useful to have some answers public.

    Best regards,

    Noah Hearle

    • This topic was modified 4 years, 10 months ago by erwinteering.

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

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Design Extreme

    (@designextreme)

    @erwinteering Thanks for posting your question on here. I will look into your request soon.

    Plugin Author Design Extreme

    (@designextreme)

    @erwinteering There is some additional functionality that is required to ascertain if the current time is before the first opening time or after the last opening time of the current day. I will add this in a subsequent version – and better support for more than one set of hours per day.

    For now, this closely resembles your request.

    [open_text]
    %if_open_today%
    	%if_closed%
    		Carwash Uden opens at <strong>%today_start%</strong>.
    	%end%
    	%if_open%
    		Carwash Uden is open until <strong>%today_end%</strong>.
    	%end%
    	%if_closed_tomorrow%
    		Carwash Uden is closed tomorrow from <strong>%tomorrow_start%</strong>.
    	%end%
    %end%
    %if_open_tomorrow%
    	%if_open_today%
    		%if_closed%
    			Carwash Uden opens again tommorrow from <strong>%tomorrow_start%</strong>.
    		%end%
    	%end%
    	%if_closed_today%
    		%if_closed%
    			Carwash Uden is open tomorrow from <strong>%tomorrow_start%</strong>.
    		%end%
    	%end%
    %end%
    [/open_text]

    The new lines and tabs are stripped out, so if you need spacing, use the replacement code: %space%. You can replace <strong> with a <span> or just strip out.

    Thread Starter erwinteering

    (@erwinteering)

    @designextreme Thanx for the response!

    The code still indicates (after closing) today’s start time and tomorrow start time simultaneously. I have simplified it for now and I am waiting for the update.

    I also use the Table version now in the footer. Perfectly adaptable to your own taste and style! Very nice!

    Thanks in advance!

    Plugin Author Design Extreme

    (@designextreme)

    @erwinteering I think a little more logic will help here – at the moment it can’t differentiate between before opening and after closing. I’ll address some of this in the next version and subsequent versions.

    Plugin Author Design Extreme

    (@designextreme)

    @erwinteering Please leave a review if you like the plugin. It’s quite new so it makes a big difference! Thanks, Noah

    Plugin Author Design Extreme

    (@designextreme)

    @erwinteering I have added new functionality to version 1.5 that will handle the text as you’ve requested:

    • %if_open_later% ? Conditional text if the business is closed, but open later
    • %if_not_open_later% ? Conditional text if the business is closed and not open later
    • %today% ? Replacement word for today’s day name
    • %tomorrow% ? Replacement word for tomorrow’s day name
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Shortcodes order’ is closed to new replies.