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

Transport data between itab and textfield on ALV event
Hallo,

I have a ALV Grid ( cl_gui_alv_grid ) and I also have hotspot click event with a h

Comment Mod System Effects all rows...
Sorry if its confusing but here is whats going on: I have a table in a database called comments and

small inaccuracies
I have this code to convert fractional base 10 into base 2:

while($num > 0)

Select Rows as Columns..
is there a way to select COLUMN_NAME from user_tab_columns where table_name='TABLENAME';
and ha

this code is strange !
Hi i got this code from the web.. It checks for live and dead socks
It is working perfectly on my

Multi Dimensional Array Append
Hi Guys

I have a function that returns a multidimentional array eg

$result = functio

How to Handle more than one submit button in single form?
Hi
I have one PHP file which contains one Form. In this form there are two Submit type Buttons

Wierd echo error?
Hi, i got the most wierd php error ever and i don't know why..
Code: echo "<t

I need an iframe that calls up a different page according to the date
hi

I don't know any php (only html) and I urgently need to do the following:

I need a

Google Map
I have done Google Map Integration for one my project. But for that we need the "latitude and l

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