PHP checkbox with date value

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

Post Reply
User avatar
sandeep605085
New php-forum User
New php-forum User
Posts: 44
Joined: Tue Feb 26, 2013 6:00 am
Location: Mindfire Solutions
Contact:

Re: PHP checkbox with date value

Post by sandeep605085 » Fri May 03, 2013 12:42 am

Hi,

It should be like
<input name="booked" type="checkbox" id="booked" value="<?php echo date('m/d/Y H:i:s'); ?>" />

Below is the reference for date function of php, you can check this to get the exact format of date you want it to be.
http://php.net/manual/en/function.date.php

Thanks,
Sandeep Agrawal
Mindfire Solutions

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest