SMSSync - missed server response


#1

Hi all!


First of all congratz for this amazing app :)


Regarding the issue, I've successfully installed the app on my phone, the incoming sms hook works well, but when it tries to sync with my web page it fail (a warning message sent failed comes up).


The strange thing is that the page page (php) is able to receive the message using post data, then it send the following message back:


echo "{ payload: { success: "true" } }";


but SMSSync seems it didn't receive the response and show the error.


Any advice would be greatly appreciated!


Have a nice day!



#2

Remove the escape character. How about you try something like this

Code:
echo json_encode(array("payload"=>array("success"=>"true")));
It's clean


#3

Thanks for the reply eyedol, but unfortunately it still not move the message in the "Sent" list.


I've tryed both solution,


with json_encode(..) the raw web page output is:

Code:
{"payload":{"success":"true"}}

with the fixed string:

Code:
{ payload: { success: true } }

but SMSSync app seems to not receive the right answer from php page.


Maybe I'm missing something, are there any log files in the app to be checked?


Thanks in advance



#4

The "Sent" list is supposed to be deleted manually actually. If the message made it to the "Sent" list, then that should be okay.



#5

Quote:
The "Sent" list is supposed to be deleted manually actually. If the message made it to the "Sent" list, then that should be okay.

Nono sorry for my bad english, I mean the message remain in the "Waiting" list and a message of send failure comes out, using both solution i wrote in my previous message.


Thanks for understading



#6

Make sure when you make an HTTP POST request, it returns {"payload":{"success":"true"}}. You could test this with a browser.


If you want to know what it is going on at SMSSync's side, install CatLog. Run SMSSync and see what's happening



#7

Yes! I've installed CatLog (nice utility by the way), and found why the server response was not handled correctly.


There was some other text before the json message ({ payload: { success: true } }) sent by the joomla framework....


Thanks again for you kind support!!!


ps. I've bought you a beer trough PP



#8

Hi,


Is it possible to acknowledege the received message

without JSON, for exemple in pure PHP ?


Thx



#9

Hi what do you mean with "pure PHP"?


If you mean without using the json encode method you can use:


Code:
echo "{ payload: { success: true } }";

which is only an echo of a string



#10

ok steax


I'll try that


Actually I'm hosting my solution on FREE Internet provider server

and they don't have JSON activate.


That's why I need the kind of solution you provide.


I'll feed you back after testing it.


Thx