Link to home
Create AccountLog in
Avatar of Dan560
Dan560Flag for United Kingdom of Great Britain and Northern Ireland

asked on

PHP date variable help

Hi,

I have inhertied a PHP script that creates a snapshot of data in a database.

There are variables that define the current dates, I need to be able to run this report as if it was ran in December 2010. After taking a look at it I'm unsure where to start and was wondering if someone can help me. I don't know any php and my work mate has left the company. I will really appreciate any help given.

Thank you
Avatar of Dan560
Dan560
Flag of United Kingdom of Great Britain and Northern Ireland image

ASKER

script attached.
domonthreport.php
Hi,

your script already seems to contain a 'fake timestamp' from dec 31, 2010. Based on the script you posted (I don't know of the other included scripts) it should look like it was ran last year. What does it do when run?

gsx1022
Avatar of Dan560

ASKER

Hi,

I'm sorry this is a different version of the report that my colleague created. It seems strange that there's a fake date in there. Attached is the current version that should be running. Which also has strange date variables that have been commented out.

To answer your question if I run the script it creates the snapshot for the current month OK.
domonthreport.php
ASKER CERTIFIED SOLUTION
Avatar of marklogan
marklogan
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Dan560

ASKER

Thanks a lot that did the trick! :)