It didn’t work. It did not turn off the embed.
Hmm that’s weird. Seemed to work when I just tested it now on my machine. Admitted I was just changing my system clock to see if it worked but I would imagine that it would do the same thing on a server.
Have you tried outputting the current day just to see if the server is set up correctly?
Best wishes,
Mark
This is what I was trying to do:
{if "{current_time format="%l"}" == "Tuesday" OR "{current_time format="%l"}" == "Thursday"}
{embed='inc/tip-of-the-day'}
{/if}
{if "{current_time format="%l"}" == "Monday" OR "{current_time format="%l"}" == "Wednesday" OR "{current_time format="%l"}" == "Friday" OR "{current_time format="%l"}" == "Saturday" OR "{current_time format="%l"}" == "Sunday"}
{embed='inc/commenter-of-the-day'}
{/if}Still very weird because if I place that exact same code in a template then it all works as it should do for me. Again admittedly I’m changing the day using my System Preferences but I would have thought that this would be the same as on a server.
Have you tried with just that code above and nothing else in the template?
Also try just this :
{if "{current_time format="%l"}" == "Tuesday" OR "{current_time format="%l"}" == "Thursday"}
Tuesday or Thursday
{/if}
{if "{current_time format="%l"}" == "Monday" OR "{current_time format="%l"}" == "Wednesday" OR "{current_time format="%l"}" == "Friday" OR "{current_time format="%l"}" == "Saturday" OR "{current_time format="%l"}" == "Sunday"}
All other days
{/if}Just to see if the correct text comes out. One other thing is you’re not using any sort of caching are you?
Best wishes,
Mark
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.