php - add 4 hours for UTC Time -


so create form outside of calendar script using.

i submitting date java date picker works great. problem script uses date subtracts 4 hours based on it's needs.

is there way add 4 hours submitted date shows correctly in admin when go approve event submitted.

example:

i submit form 10:00 admin reads 6 am

the code in admin of script compensating utc.

<?php    if (!isset($_post['submit'])) {    ?>    <?php     } else {    $input_arr = array();    foreach ($_post $key => $input_arr) {        $_post[$key] = addslashes($input_arr);     }   $user_id = $_post['user_id'];   $listing_id = $_post['listing_id'];    $status = $_post['status'];    $title = $_post['title'];    $description_short = $_post['description_short'];    $description = $_post['description'];    $venue = $_post['venue'];    $location = $_post['location'];    $admission = $_post['admission'];    $contact_name = $_post['contact_name'];    $website = $_post['website'];    $email = $_post['email'];    $phone = $_post['phone'];    $date = $_post['date'];    $date_start = $_post['date_start'];    $date_end = $_post['date_end'];       mysql_query("insert `pmd_events` (user_id, listing_id, status, title, description_short, description, venue, location, admission, contact_name, website, email, phone, date, date_start, date_end) values ('$user_id', '$listing_id', '$status', '$title', '$description_short', '$description', '$venue', '$location', '$admission', '$contact_name', '$website', '$email', '$phone', '$date', '$date_start', '$date_end')");     $id = mysql_insert_id();     mysql_query("insert `pmd_events_dates`     (event_id,date_start,date_end,rsvp_reminder_sent) values ($id,'$date_start', '$date_end',0)");    echo "verbage";    }     ?> 

its what's being submitted contains time zone. difference submitted vs submitters timezone.

either don't send time zone or trim value ignore time zone. both


Comments

Popular posts from this blog

c - Bitwise operation with (signed) enum value -

xslt - Unnest parent nodes by child node -

YouTubePlayerFragment cannot be cast to android.support.v4.app.Fragment -