Reputation: 248
I'm developing application for windows phone 8 and I need to get user data from remote MySQL database. This database is also used by the web-application.
What is the solution for this problem? Where I can read some information about using remote data storages with windows phone 8?
Upvotes: 1
Views: 1381
Reputation: 133
A better and simpler way is to perform all the db operations in server side code (like php) and the information can be passed to the php file using a query string and the reverse by echo statement.
var webclient = new WebClient();
webclient.OpenReadAsync(new Uri("http://website.com/filename.php?name=" + myname.Text );
webclient.OpenReadCompleted += new OpenReadCompletedEventHandler(handler);
private void opener(object sender, OpenReadCompletedEventArgs e)
{
// throw new NotImplementedException();
using (var reader = new StreamReader(e.Result))
{
string response = reader.ReadLine();
MessageBox.Show(response);
}
}
Upvotes: 0
Reputation: 1092
You can use the restsharp client for windows phone. Its fully documented and a nuget install is also available. heres the link http://restsharp.org/
Upvotes: 1