May 7, 201510 yr Newbies I'm having a lot of trouble figuring out how I should be formatting a Time for input into a field. How should I do this? I was able to input a date by taking a date with the format MM-DD-YYYY and putting it through date() and setting a date field to that, but I can not for the life of me get time to work. I'm working from a form, so I can format the initial input to the page however I'd like, and just need to know how I can get FileMaker to accept it for a time field. Thanks all
May 7, 201510 yr I believe FileMaker wants the format HH:mm:ss So assuming an hour (24 hour) and minute field on the form $hour = $_REQUEST['hour']; $minute = $_REQUEST['minute']; $input = $hour .":".$minute.":00"; Dates are natively mm/dd/yyyy so just formatting the form input to that should work.
May 8, 201510 yr You should also be able to set your field using the Time(hh; mm; ss) command: $enterTime = $foundRecord->setField(;yourTimeField', "Time(" . $hour . "; " . $minute . "; 00)";
Create an account or sign in to comment