[eluser]ninjayan[/eluser]
Hello everyone!
I am currently developing a document tracking application which will calculate the duration of document.
So the number of days to be added from the current date (document creation) is set from the database (dynamic).
I have this code but this will not make it dynamic since the number of days to be added is hard coded.
Code:
$add = 5;
if ($add == "5") {
$xa = date("Y-m-d", strtotime("+7 days"));
}elseif ($add == "10") {
$xa = date("Y-m-d", strtotime("+14 days"));
}
echo $xa;
So the code above is just to illustrate what I want to achieve.