I would like to create 5 variables. They should hold the date('Y-m-d') values of each business day in the current week number.
For example (this week)
$mon_value = 2012-07-30
$tue_value = 2012-07-31
$wed_value = 2012-08-01
$thu_value = 2012-08-02
$fri_value = 2012-08-03
And this should update automatically when the week number changes.
How would I achieve this? I am fairly new to PHP programming…
PHP has a nifty function called strtotime, which can be used in the following way:
Combine that with the date function and you can have the date of each day:
strtotime documentation