but the problem ist that i got time from textfields and it PHP takes them as string and therefore i m facing difficulties to calculate day differences between two dates:
@NightShift58Mar 07.2007 — #the strtotime() function should convert the date to time
i think that wat NightShift58 is trying to say <i> </i>$ts_date1 = strtotime($_POST['date1']); $ts_date2 = strtotime($_POST['date2']); [/QUOTE]No, actually not. Usually, dates selected in <SELECT> come in 3 parts: month, day and year. If you want my thoughts in detail, it would be this:[code=php]<?php $date1 = $_POST['year1'] . "-" . $_POST['month1'] . "-" . $_POST['day1']; $date2 = $_POST['year2'] . "-" . $_POST['month2'] . "-" . $_POST['day2']; $ts_date1 = strtotime($date1); $ts_date2 = strtotime($date2); ?>[/code]But the OP will have to know how and what to concatenate because you and I can only assume things.