Grabbing Data from A Website?

Hey,

Hoping to figure out how I can let users log into a website through my app, and then access their account info via the app too. Its a student profile system that every student has a username and password for. Trying to make it so people can view grades in the go. I just have no idea where to start/search, any direction would be great. [import]uid: 179420 topic_id: 32182 reply_id: 332182[/import]

Also wondering, if this is not possible, then is it possible to load the website in the background, grab info from that, and display it via my own custom interface in the app? [import]uid: 179420 topic_id: 32182 reply_id: 128115[/import]

Hi Kevin,
Depending on your specific need, you can likely query a website or server using Corona’s network capabilities. I don’t have a specific guide for your app concept, but please look here as a starting point:

http://docs.coronalabs.com/api/library/network/request.html

You can also put live Web views directly into Corona, which might accomplish your goal.

http://docs.coronalabs.com/api/library/native/newWebView.html

Finally, on a more advanced level, you might be able to output your student user info to an XML, JSON, or text file and then retrieve that via FTP in Corona, then parse it and use it to create a custom “login” procedure.

I hope this helps in some way,
Brent Sorrentino [import]uid: 9747 topic_id: 32182 reply_id: 128116[/import]

Thanks Brent, that was helpful, definitely gives me somewhere to start. [import]uid: 179420 topic_id: 32182 reply_id: 128122[/import]

Also check this out:

http://omnigeek.robmiracle.com/2012/04/15/using-corona-sdk-with-rest-api-services/

Basically if your webserver can run PHP scripts (or other scripting languages) then you can use them to create data that your app can easily consume using network.request()

[import]uid: 19626 topic_id: 32182 reply_id: 128162[/import]

Also wondering, if this is not possible, then is it possible to load the website in the background, grab info from that, and display it via my own custom interface in the app? [import]uid: 179420 topic_id: 32182 reply_id: 128115[/import]

Hi Kevin,
Depending on your specific need, you can likely query a website or server using Corona’s network capabilities. I don’t have a specific guide for your app concept, but please look here as a starting point:

http://docs.coronalabs.com/api/library/network/request.html

You can also put live Web views directly into Corona, which might accomplish your goal.

http://docs.coronalabs.com/api/library/native/newWebView.html

Finally, on a more advanced level, you might be able to output your student user info to an XML, JSON, or text file and then retrieve that via FTP in Corona, then parse it and use it to create a custom “login” procedure.

I hope this helps in some way,
Brent Sorrentino [import]uid: 9747 topic_id: 32182 reply_id: 128116[/import]

Thanks Brent, that was helpful, definitely gives me somewhere to start. [import]uid: 179420 topic_id: 32182 reply_id: 128122[/import]

Also check this out:

http://omnigeek.robmiracle.com/2012/04/15/using-corona-sdk-with-rest-api-services/

Basically if your webserver can run PHP scripts (or other scripting languages) then you can use them to create data that your app can easily consume using network.request()

[import]uid: 19626 topic_id: 32182 reply_id: 128162[/import]