Scheduler doesn't work with PHP/MySQL

Has anyone managed to get Touch Scheduler to work with PHP/MySQL?
I can successfully load the data, but cannot add, change. I am using the Scheduler Connector. I made some changes to scheduler.js as follows: = "data/mobile_load.php?user=3";

// if(!this.config.readonly&& … I removed this line
new dhx.DataProcessor({

I suspect the problem has something to do with the date format, which is posting in full format instead of yyyy-mm-dd hh:mm as the database expects. I changed the code in Save as follows:
case “save”:
var data = this.$$(“schEditForm”).getValues(); = dhx.uid();
data.start_date = convert_date(data.start_date); // added this
data.end_date = convert_date(data.end_date); // and this
} else {

My convert_date function is UGLY, so I won’t share it with you, but it works! When the date format is correct, the record is successfully added (although I have to refresh before it’s visible). I think I need the Touch equivalant of scheduler.config.xml_date. Does that exist?
When I try to change an event, it actually DELETES the record. Again, the date format in the POST is incorrect - I’m not sure how to fix this.
Any suggestions? Thanks :slight_smile:


scheduler.config.xml_date that sets the date format for date in datasource is “%Y-%m-%d %H:%i” by default:
scheduler.config.xml_date = “%Y-%m-%d %H:%i”

Please check the sample with (PHP/MySQL):

Thanks Alexandra.
I went back to basics at the weekend and started building the app from scratch using the samples rather than the mobile scheduler and it’s working pretty well. I have run into some other problems, but they are not related to the connector so I’ll raise separate posts for them.
Thanks again for your help.