How to calculate days from variable date?


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

This will be easy for one of you gurus. I want to fetch the date from a variable date, for example:

Code: <?php
$mydate = "";
Did you know?Explore Trending and Topic pages for more stories like this.
$daysaway = 400;
$startdate = "5/5/2005";

//I need how to get the date that was 400 days ago

print "$mydate was $daysaway days from $startdate.";
?>
No comments posted yet

Your Answer:

Login to answer
223 Like 50 Dislike
Previous forums Next forums
Other forums

what does this mean? +=
is anyone able to explain what this code is saying?

i had it written for me awhile back and n

Help with some dates
I have a list of dates in an array:

$mondays = array(
strtotime("October 12, 2009

Socket problem
Hello,

Earlier I posted about my problem with my socket script. It took up to 100% CPU usage.

start new row of pictures
on my site www.budstreasureauctions.com there is a featured auctions box that users will pay to get

Need help in Generating Combinations
Need help generating all possible combination of names in an array

Lets say i have the follow

ob_ dynamic content
i was wondering about the potential to use ob to create a <div then remove it when the page

chat
hello i'm amir i need a chat source code in asp.net 2.0 without Ajax. anybody can help me?

SHOW TABLES Help
Hi all

I have the following

Code: [Select]<?php
$sql = "SHOW TABLES&quo

Filtering an Array Based on Value
I have a very simple script set up that pulls data from a database and is output using this code:

SAP BCS. BPS
Hi all,

I am seeking reading note on the following in BW

BCS, BPS
ADVANCE

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