#weekday()
DESCRIPTION
returns the current weekday (1-7)
or:
returns the weekday (1-7) of the given datevalue
SYNOPSIS
#weekday()
or:
#weekday(d)
ARGUMENTS
none
or:
d - a datevalue, or datevalue expression
EXAMPLES
# pikt +C 'output $text(#weekday())'
4
# pikt +C 'output $text(#weekday(#today()))'
4
begin
if #weekday() == 1 || #weekday() == 7
quit
fi
sunday ( #weekday() == 1 )
monday ( #weekday() == 2 )
tuesday ( #weekday() == 3 )
wednesday ( #weekday() == 4 )
thursday ( #weekday() == 5 )
friday ( #weekday() == 6 )
saturday ( #weekday() == 7 )
begin
if =sunday || =saturday
quit
fi
bypass_server_reboots
if $host =~ "$servers"
if =server_reboot_period(#weekday(), #hour())
next
fi
fi
SEE ALSO
#day()
#daynumber()
#month()
#monthnumber()
#year()
#yearday()
#yearweek()
$dayname()
$monthname()
Numerical Functions
String Functions