On Fri, 20 Feb 2015 22:52:22 -0500, Jerry Stuckle wrote:
> I looked at it briefly, but not nearly as deeply as you did. From what
> you said, I agree it's pretty convoluted. However, I see they also have
> a PHP driver; are there any phones out there which run PHP? Or is it
> something you can put on a PC or server to send SMS messages from there
> (I still don't know how you'd receive a message).
Oh - yeah, maybe it's a case of using your PHP app to send and receive
messages via your phone ... that might be more useful (I did wonder about
writing apps in php on a phone).
The only way I can see to receive messages is to poll their server for
them from the php app, which would either mean running a cron job
(reliable) or relying on someone accessing the PHP code manually to
trigger a poll.
Assuming the idea is that the php would be sitting on your web server
(now makes more sense I guess) that really means a cron job to poll for
incoming messages.
But even so, assuming the phone has an ip address, it would make more
sense for a phone app and your web server to communicate directly, rather
than via a third party server.
Hang your phone off the wifi on your lan, get the phone's lan ip, tell
the api code on the webserver to make it's rpc calls to the phone ip on
whatever port the phone app listens to. Then a java app on the phone
handles the rpc calls from the webserver and interfaces with the phone's
sms api.
And a third party isn't harvesting data from your sms traffic (except for
NSA / GCHQ and the mobile network operator, but that's hard to prevent).
Writing a java app for android to listen on a nominated port, receive a
json string over tcp/ip, talk to the phone sms api and then respond with
a json string over the same tcp/ip connection wouldn't be difficult.
--
Denis McMahon,
denismf...@gmail.com