kalawati — 2012-11-07T01:42:13-05:00 — #1
I want to develop an application (probably client app) in php which stores data in offline and submit data to server later on when internet access is available.
This application is supposed to be run in remote part where internet access is rarely available so data are to be stored offline... when internet connection is available these offline data are to be submitted into the server.....
Waiting for reply as soon as possible
cpradio — 2012-11-07T05:22:04-05:00 — #2
PHP is primarily a server side language so internet connection or a running local server would be required. Granted there have been a few projects that have tried to bring PHP to a desktop application (like gtk-php), none of them have really stuck around and may have very limited support.
You would be better off writing your client app using a different language, Python, QT, .NET Framework, etc.
Without knowing what your client is (a laptop, desktop, mobile phone), it is hard for me to recommend what path to take.
kylewolfe — 2012-11-08T14:37:47-05:00 — #3
I don't see any reason why a local intranet site couldn't be be done in PHP along with a local copy of MySQL or similar. Then create a simple update / append query to send off to the remote server. With PHP 5.4 you wouldn't even need Apache or IIS since it has a simple web server built in. I'd create a simple batch script to 1) launch an instance of PHPs web listener 2) attempt or ask you if you want to attempt an SQL update to remote server and then 3) launch http://localhost
cpradio — 2012-11-08T16:28:34-05:00 — #4
Too many assumptions there. If you are building for mobile phones, that is entirely out of the question, if you are building for other handheld devices, it again, may be out of the question. I'd never use PHP as a client in a scenario like that, as it was never intended to be used that way. There are other languages/options that are far better suited.
kylewolfe — 2012-11-08T16:31:38-05:00 — #5
I didn't see anything about mobile devices, but a properly coded site should work fine on mobile. I totally agree that there are better suited languages for the job, but in a pinch, or as a start with something familiar, it should work.