Page 1 of 1

How to send/post data to a database?

Posted: 23:46, 24 Feb 2015
by evo_fan
Hi guys,

Just recently started using Evothings. Is there a tutorial or well-known way to send/post the collected data to a mongodb or mysql database server? I am using the client on IOS.

Thanks!

Re: How to send/post data to a database?

Posted: 15:52, 15 Mar 2015
by micke
Hello,

Sorry for the extremely slow response on this one.

What you could use is standard web techniques for interacting with the database server. That would likely be based on using AJAX (XHR). jQuery is great for this.

Perhaps something like this could be used?

http://etoxin.net/blog/2013/07/09/mongo ... 0-minutes/

Another approach could be to implement a native Cordova plugin that handles the communication with the database server. This is more work to implement and maintain compared to the XHR-solution, and may not be any more performant in the end.

If you need to store local data the localStorage in HTML5 is very easy to use (this is not a database however, just mentioning in case it would be useful).

Let me know how it goes.

Best regards, Mikael