hi people
i need a function that takes in two dates and computes the difference between them but with a condition, exclude all saturdays and sundays within the specified period.
i was able to do a countdays function but the results are in calendar days, that is, it includes saturdays and sundays.
My idea is to loop through the start and end dates and put the results into an array variable. Within the loop i plan to put a condition like if(!$dayofweek == "Sun" || !$dayofweek=="Sat"), to prevent the array from getting the "Sat / Sun" days of the week and then use count function to sum up the array. Will this work? I appreciate any feedback from u guys. thanks a million.🙂