Problem on Date Function

From: Date: Tue, 03 Jun 2003 09:40:56 +0000
Subject: Problem on Date Function
Groups: php.general php.windows 
Request: Send a blank email to php-windows+get-20169@lists.php.net to get a copy of this message
Dear all Here is the situation : Our automation system will generate a large number of pdf file to a specific folder every day. The name format for all these pdf file is "xxxx.20030602.pdf". xxxx is the name of the file, 20030602 is last working date. what i want to do is: 1. create a sub-folder inside this specific folder, and name it to current month(Jun-2003) 2. move the pdf which is not containning last working's file name to this new create sub-folder. 3. the files with last working date's name will stay on the specific folder. question : 1. I had used a date function with "w" parameter to check if current date i execute the script is monday (1), if so , i tell the script to take the current date minus 3, so the date will become last friday (as our last working day), then i can base on this date to tell the script which files should not be move to sub-folder! q: how i can do a date subtraction in php? (eg. "2003-06-02" - 3 = "2003-05-30")

« previous php.windows (#20169) next »