I would recommend using a combination of Switchee and IFElse , both from Croxton, to make this analysis faster, as it is rather complex conditional. How about something like that, for example?
{exp:switchee var="{current_time format='%l'}" parse="inward"} {case value="Monday|Tuesday|Wednesday|Thursday|Friday"} {exp:ifelse parse="inward"} {if '{current_time format="%H%i"}' >= '0600' AND '{current_time format="%H%i"}' <= '0959'} Morning show {if:elseif '{current_time format="%H%i"}' >= '1000' AND '{current_time format="%H%i"}' <= '1459'} Midday Show {/if} {/exp:ifelse} {/case} {case value="Saturday"} Do the same sort of thing for Saturday {/case} {case value="Sunday"} Do the same sort of thing for Sunday {/case} {/exp:switchee}
Also note that I adjusted the time by 1 minute - otherwise two conditions in the same set (because you use equal or less / more) can be true at the same time.
source share