how to send the date value as string to database

Hi, I placed a datepicker UI in the page and I made the current date as default date. I want send the date value that user choose to the database but I failed.

Please tell me how to send the date value to the database as string.

This is the code I used:

var d = Appery("datepicker").getAttr("defaultDateValue"); //(I am not sure the attributes of the datavalue, users may change the default date that I preset. I need to get the real date they picked)


then I map the local storage variable "reportdate" to the database.
2 people have
this question