fixed field names
fixed php file's syntax error. tested it and it works