Help with some dates


Posted on 16th Feb 2014 07:03 pm by admin

I have a list of dates in an array:

$mondays = array(
strtotime("October 12, 2009"),
strtotime("October 19, 2009"),
strtotime("October 26, 2009"),
strtotime("November 2, 2009"),
strtotime("November 9, 2009"),
strtotime("November 16, 2009")
);


It is an array of the next few mondays. I am wondering how I could figure out what the next monday in the array is depending on the current time, using time();

I cannot use strtotime("next monday") or strtotime("+1 monday") because the server I am working on is using a very old version of PHP (4.3.10-22) and it has a bug when I use strtotime("next monday");...I am also not able to upgrade the version of PHP.

No comments posted yet

Your Answer:

Login to answer
286 Like 16 Dislike
Previous forums Next forums
Other forums

Passing variables with pagination - iterating through unique id per link
Hi everyone,
I have seen a few topics like this one. Still cant find the specific thing, so I am

Not capturing all the information we require in the form.......
Hi Guys,

I was wondering if you would share some more of your knowledge today, I'm hoping it

Time script, set to my time zone?
I am using this line to get the date and time

Code: $time = date(F." ".d.", &q

getting weird error..
okay, I'm getting an error on this particular function, something about the syntax in the mysql LIMI

Can't find a decent web analytics!!!
I've downloaded and installed Piwik. It's location detection based on IP addresses is fairly inaccur

Company Code for Vendors created through Business Partners
Hi, experts!

I'm trying to set up the integration between Business Partner (BP) and Vendo

simplexml_load_file and rss problem
Hi,

I have a problem parsing an rss feed using simplexml_load_file - this is strange as i hav

Odd or Even
Inside of a while loop I need to echo several rows of info...easy enough.

In the loop (for th

Not showing whole name with mail () script
I sent up a simple mail form with the PHP mail() script. One problem is when it sends an email with

PHP form help required
Hi all! Apologies in advance for having to message the forum for help. I know you must get a lot of

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash