Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter("gform_post_data", "change_post_date", 10, 3);
- function change_post_date($post_data, $form, $entry){
- if($form["id"] != 1) //FORM ID
- return $post_data;
- $date = $entry[13]; //INPUT ID
- $post_data["post_date"] = date("Y-m-d", strtotime($date));
- return $post_data;
- }
Advertisement
Add Comment
Please, Sign In to add comment