# Date formats... Pls help

**URL:** <https://forum.kirupa.com/t/date-formats-pls-help/324011>\
**Category:** Uncategorized\
**Created:** [July 28, 2011, 9:12am UTC](https://forum.kirupa.com/t/date-formats-pls-help/324011 "2011-07-28T09:12:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![surf](https://avatars.discourse-cdn.com/v4/letter/s/77aa72/32.png) [@surf](https://forum.kirupa.com/u/surf)\
**Post date:** [July 28, 2011, 9:12am UTC](https://forum.kirupa.com/t/date-formats-pls-help/324011/1 "2011-07-28T09:12:46Z")

</div>

Hi I am abit stuck… i have a form with the following code

```php

<form action="" method="post">

<label>Signin date</label>
<input type="text" name="signInDate" >
<input type="submit" value="Submit">
</form>

```

and on the same page i have

```php

if(isset($_POST['signInDate']))
	{
	$signing = $_POST['signInDate'];
	$inputDate = date("d-m-Y",strtotime($signing));
	$newdate = strtotime('+3 day, +2 month' ,strtotime($signing)) ;
	$newdate = date("Y-m-d",$newdate);

	        $newdate = strtotime('+17 day, +0 Month' ,strtotime($signing)) ;
		$newdate = date("d-F-Y",$newdate);
		
		echo "date Input was " . $inputDate ;
		echo "<br>date calc is " . $newdate . "<br>" ;
	}

```

The calculations are fine but to make it work the dates in the form for some reason is needs me to add in this format mm/dd/yyyy

i want it to be input in dd/mm/yyyy …  
any help or suggestion will be appreciated

Surf
