How to Export Data From an App & Display It on a Website

  • Thread starter Thread starter Moneer81
  • Start date Start date
  • Tags Tags
    App Data
AI Thread Summary
A beginner is developing a hybrid app using Smartface that counts down from 30 minutes, awarding stars for completed sessions. The goal is to export and display the total stars collected on a webpage. Suggested methods include using MySQL for data storage and PHP for displaying the data on a website. A simple approach involves sending data via a GET request to a PHP script, although this method raises security concerns, as it could allow unauthorized requests. To enhance security, generating unique codes for requests is recommended. Additionally, using JSON for data transfer between the app and PHP is advised for seamless integration. Despite concerns about PHP's security, it remains a widely used and trusted technology for web development.
Moneer81
Messages
158
Reaction score
2
Hello,

Beginner here so take it easy. I am building a basic hybrid-platform app using Smartface (a similar platform to Phongap). For purposes of this discussion, the app will do something very basic: you click the start button and it will start counting down from 30 minutes to 0, and when you reach 0 you get 1 star. You can do this multiple times in a day. The more 30-minute sessions you complete, the more stars you get.

What I would like to do is have those stars exported and displayed on a webpage. In other words, I would like the user to browse to that website and see how many stars were collected over a day.

Now what is the easiest way to do this? I have been looking into the Parse platform, and into some of the authentication services out there. I also have a hosting package that includes MySQL and a decent amount of storage/bandwidth.

Without diving into complex discussions of building a backend infrastructure, what is the simplest way to export this very basic data and simply display it on a webpage?

Thanks in advance.
 
Technology news on Phys.org
Storing the data in mySQL and displaying it using something like PHP would be fairly easy depending on the tools you have available for developing your app. However why even introduce the browser? Just have it stored locally in the app.
 
To expand a bit on what Greg said, an super easy (and insecure) way would be to set up the app to send the information via a get request to a web url.
Something like www.yousite.com/postStar.php?id=123

then have a little snippet of php code which will insert the data into a webpage

It's insecure as what prevents people from generating their own requests?
You can make it a bit more secure by having the app generate codes, but with anything if someone is motivated they'll figure a way to break through :)
 
Thank you both! This explains things a little better!
 
Moneer81 said:
Hello,

Beginner here so take it easy. I am building a basic hybrid-platform app using Smartface (a similar platform to Phongap). For purposes of this discussion, the app will do something very basic: you click the start button and it will start counting down from 30 minutes to 0, and when you reach 0 you get 1 star. You can do this multiple times in a day. The more 30-minute sessions you complete, the more stars you get.

What I would like to do is have those stars exported and displayed on a webpage. In other words, I would like the user to browse to that website and see how many stars were collected over a day.

Now what is the easiest way to do this? I have been looking into the Parse platform, and into some of the authentication services out there. I also have a hosting package that includes MySQL and a decent amount of storage/bandwidth.

Without diving into complex discussions of building a backend infrastructure, what is the simplest way to export this very basic data and simply display it on a webpage?

Thanks in advance.
In addition to what's been said, JSON is the way to send data from javascript (phonegap) apps seemlessly to PHP. Google it and see how easy it is.
 
Isn't PHP notoriously insecure?
 
Moneer81 said:
Isn't PHP notoriously insecure?

Moneer81 said:
Isn't PHP notoriously insecure?
https://www.quora.com/What-are-the-top-10-websites-built-with-PHP ... I've been away from web development for awhile, but unless something new has come up, its pretty trusted.
 
Last edited by a moderator:
Back
Top