Hi i am creating a reservation system and I have working days(Monday,Tuesday,Wednesday etc) in an array I want to display the next 8 working days from now onwards.

What i am doing is

        if(in_array(date("l", strtotime("+".$no." days")), $days_arr))
            echo date("D d M", strtotime("+".$no." days"))."<br>";

And the whole takes hell lot of time to execute i don't know why

$working_days_arr consist

$working_days_arr[0]=Monday,Tuesday,Wedneday etc

and 5-6 more element in $working_days_arr array

I hope my query is clear

0 Answers