Hi everyone, I’m going crazy because I don’t understand what the problem is…
By clicking on that url that I wrote, the response you get via the browser (for example Google Chrome) is: |0 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0
and it’s perfect!! So no problem so far…
But if I do the exact same thing via the smartphone app (app created with appinventor and working for years on other hosting service sites) instead of answering the one or zero line as above, I get the answer:
I really can’t understand…
basically the app I made has a button which, if pressed, runs the URL I wrote and displays the response text which is the error written just now… even if I open a browser from my mobile phone and write the 'url the answer is correct… what am I doing wrong… what authorization should I remove?.. the files are all 777, inside the “miscellaneous” folder I put the index.html file…
The security system requires JavaScript and cookies to be enabled on a browser, it presents the browser with a JavaScript challenge which, when solved by the browser, saves a cookie that allows you to progress. Does your AppInventor browser support executing JavaScript and storing cookies?
I enabled cookies (I saw that the web service that sends the URL has a box that was not enabled that says “enable cookies”)
now the response I get is practically the same but there is an extra line under
<hr><center>nginx</center>
Can this writing help?
Is this the code I should send back?
sorry, I’m trying them all at least to close the dream… that everything worked…
If this is only happening in AppInventor2, you need to have a WebView Component going instead of the Web Component, as WebView runs JavaScript to get past the security challenge while Web only executes the request. WebView is a type of browser and yes you also need to enable Cookies in that to keep you going.
403 simply means your request is rejected. With the Web component, you might not be following redirections so the final response code is 403 instead of the 302 redirections to Google.
Let us know if that’s helping you proceed and let us know if you have any issues after making the change.