Solved

Write an app

Posted on 2016-09-30
10
60 Views
Last Modified: 2016-11-25
What is the diff between writing a php page and making into an app?  Can someone point me to a page to write an app?
0
Comment
Question by:breeze351
  • 3
  • 2
  • 2
  • +2
10 Comments
 
LVL 82

Assisted Solution

by:Dave Baldwin
Dave Baldwin earned 250 total points
Comment Utility
It is actually quite different.  An 'app' starts from and runs on the client's device.  Web pages start from the server and run in the browser.  Since an 'app' is basically a program running the device, it has different privileges than a page a in web browser.  Apps for phones are written in JAVA for Android and Apple's Xcode for iThings.  Apps also have to be approved to be downloaded and installed from the Google and Apple stores.
1
 
LVL 30

Assisted Solution

by:Marco Gasi
Marco Gasi earned 125 total points
Comment Utility
To write an app you can also use html5, javascript and css3 to write a hybrid app which will be converted into a native app for Android and/or IOS and/or Windows mobiles by Cordova/Phonegap plugin.

There are several framework  to help you to do this: jQuery Mobile, Ionic and many others: just Google for hybrid app

From within a hybrid app, which is foundamentally a web application, you can connect to a remote server when your php scripts can execute, perform database queries and any other task you wish returning a result. In order to connect to a remote server from within your app you'll have to use jsonp: personally, I'm happy using this jQuery plugin and write your Ajax calls using a special tecnique... but I'm going too forward. If you'll go to write a hybrid app, using jQuery Mobile you'll can post any new question here and I'll be happy to help you, if I can :)
0
 
LVL 51

Assisted Solution

by:Julian Hansen
Julian Hansen earned 125 total points
Comment Utility
What is the diff between writing a php page and making into an app?
PHP is server side code - you can use it to write service endpoints that an app connects to but you won't write the app itself in PHP. With most internet based applications you have to define a stack - this is the combination of backend and client side technologies you will use to deliver the app experience to the end users. In a particular stack you might make use of PHP to deliver content back to the device where the app is running. As Marco and Dave have pointed out though the actual app runs locally on the device - and will either be coded in the native language for the device or using a hybrid solution like Cordova or ReactJs Native etc.
0
 

Assisted Solution

by:breeze351
breeze351 earned 0 total points
Comment Utility
Where would the data reside? On the server side or does it have to be downloaded to the client?
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 30

Assisted Solution

by:Marco Gasi
Marco Gasi earned 125 total points
Comment Utility
This depends on your choice and your needs. If you download dta from the server to store them locally on the device you can use SQLite. Keep in mind the SQLite doesn't support relational database so you can't have foreign keys, for instance. This kind of things depend on the type of the app you're going to create, the amount of data, if the app must be work even offline and so on.
0
 

Assisted Solution

by:breeze351
breeze351 earned 0 total points
Comment Utility
I have the page running in PHP on a server and it does work.  Do I really to convert it to an app?  I understand that the app runs on the client, but why does it matter?
0
 
LVL 30

Assisted Solution

by:Marco Gasi
Marco Gasi earned 125 total points
Comment Utility
I'm not sure: are you asking why you should worry about creating a mobile app from your web application? That depend on several factors. If your web application looks great in mobile device you could just go on with it, unless you need some specific features like, for instance, push notifications or if you can improve the appliction using mobile plus like camera, gps and so on
.
In addition, you could create an app just to follow the trend: mrketing and commercial considerations could be enough to decide to create a mobile app...
0
 
LVL 82

Accepted Solution

by:
Dave Baldwin earned 250 total points
Comment Utility
If your 'app' would do nothing more than the web page does, then there is no reason to convert it to an 'app'.  However, you can't directly convert your PHP page into an 'app' for all the reasons listed above.  #1 is that the phones don't run PHP.  A lot of companies appear to have their own 'apps' for vanity reasons... but vanity seems to sell well to a lot of people.
0
 
LVL 108

Expert Comment

by:Ray Paseur
Comment Utility
I was out of town when this question was posted, but I'd like to add one comment about this part:
Where would the data reside?
That could be one of the more important questions of the design.  In round numbers it takes about 10x as much electrical power to get data from a server, compared to getting the data from in-device storage.  This has implications for battery life, so if you can cache information in the device you will do your client community a great favor.  Further to this point, any scheme that does repeated or unnecessary polling of the server should be considered a design flaw.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
This article discusses how to create an extensible mechanism for linked drop downs.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now