Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PHP to Android Phone

Status
Not open for further replies.

CamaroLT

Programmer
Dec 16, 2002
159
0
0
CA
Its been a while since I've posted anything here, and its usually because before I submit the form, I find my solution. However, I'm feeling somewhat "in over my head" on an enhancement to a project of mine.

Under a LAMP config, I've written a web app that displays my work schedule, home schedule, school schedule, notes (Typically honey-do notes), displays a yearly calendar including all previously mentioned schedules, and a grocery list. It works rather well, and I'm getting my wife to use it more often. SCORE FOR ME. :] This software (I call HomeCal) is not publicly accessible to the Internet, and is setup to run only on my home LAN or via VPN. Apache is hard wired to only allow LAN IP addresses to connect to this service. (Basically,
Bottom line, what I want to do is when I push a button on HomeCal, the current grocery list is transmitted to both my cell phone, as well as my wifes cell phone, both of which are on two different providers (Rogers and Telus). What the grocery list contains could be just plain text, or, HTML to make it look fancy in a browser, or whatever.

100% of the time when I'd be using HomeCal and broadcasting a new grocery list to my phones, I would at least be in Cell Service area, so an immediate push to the phones 'should' be successful at that time.

I've looked at SMS, but, I have to tell the Rogers bots to authorize the text message every time I send a message to my phone. EMailing is also kind of out of the question as I have anything to do with syncing on my phone turned off.

I've looked at DropBox, but my problem with that is that the DropBox application must be actively running on the phone, and the phone is either on my wifi or in cell service to get an active sync going. I try to run as few applications and services on my phone for battery longevity.

I've quickly looked at GCM (Google Cloud Messaging) but it looks like I'd have to write some Java code and have a service/application run on my phone. I took Java in my college days and absolutely none of it stuck. I can setup a work environment without too much of an issue, but doing the actual coding and stuff.. well... invest in WD-40 stock if I take that on.

So given those three options, I've not put out of my mind the feasibility of just my getting un-lazy and remember that when we're on our way out to get groceries, I forcefully have my phone update the list as a text file through a web server that is exposed to the internet, and download a text file, or have DropBox load and update.

Are there any other options available anyone can think of that'd get to my end goal of pushing a button on my HomeCal web page and have data transferred to my cell phone?

-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=
NEVER send the boss to do a techs job
 
This figures.... Found a solution. Cost me $5USD, but it works.


I installed the application on my phone, I have the PHP working, and voila, I can send my grocery list.

-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=
NEVER send the boss to do a techs job
 
As an explanation of why, if you don't know already, is that PHP code only runs when invoked by a call to the code and as HTTP is a 'disconnected' or "on request" protocol, the external device HAS to make a request to the "web service" (polling) to start the PHP code running.

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Oh, absolutely I understand about the disconnected state of the web, and knew I had to rely on an external resource to PHP of some sort, either by using DropBox, SMS or something of the sort.

I was looking for technology that would assist in getting information to my phone in a free/cheap and easy manner, and NMA did the job quite well. It actually beat the mantra of "Cheap, Fast, Easy - Pick two" because I got it working cheaply ($6cdn), easy (Someone had written a PHP class for this service already) and fast (Two different types of transmissions done within a 12 hour period). Not only do I now have NMA singing to my phone for my grocery list, but I have it telling my phone when my PBX system goes down.

The only problem I have with NMA is it SEEMS that the developer has gone MIA. I'll probably start looking at resources that'll get me to talk to the Google push services myself as I don't sense this guy is serious, or is going to be around "forever".


-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=-=*=
NEVER send the boss to do a techs job
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top