lock255 Well-Known Member Licensed User Longtime User Mar 9, 2014 #1 Hello everyone, I have created an app that shows the status of a site (UP / DOWN), but is misled when the site has a redirect. How do I get "stop" the redirect?
Hello everyone, I have created an app that shows the status of a site (UP / DOWN), but is misled when the site has a redirect. How do I get "stop" the redirect?
Erel B4X founder Staff member Licensed User Longtime User Mar 9, 2014 #2 You will need to use HttpUtils2 code modules instead of the library and add: Code: Copy hc.SetHttpParameter("http.protocol.handle-redirects", False) http://www.b4x.com/android/forum/threads/httprequest-redirects.8132/#post45790 Upvote 0
You will need to use HttpUtils2 code modules instead of the library and add: Code: Copy hc.SetHttpParameter("http.protocol.handle-redirects", False) http://www.b4x.com/android/forum/threads/httprequest-redirects.8132/#post45790
lock255 Well-Known Member Licensed User Longtime User Mar 9, 2014 #3 I did not understand where I need to insert this line of code in the module HttpUtils2. PS: I have read the link that I have posted. Upvote 0
I did not understand where I need to insert this line of code in the module HttpUtils2. PS: I have read the link that I have posted.
Erel B4X founder Staff member Licensed User Longtime User Mar 9, 2014 #4 You should put it in HttpUtils2Service Service_Create (after hc is initialized). Upvote 0
lock255 Well-Known Member Licensed User Longtime User Mar 31, 2014 #5 Ok, I followed your instructions but on my adult site (perversioncity.com) that has a redirect if it appears to be moving. Although your code takes the same redirect. Now I wonder if it is a code problem or this type of redirect that can not be "deleted"? Upvote 0
Ok, I followed your instructions but on my adult site (perversioncity.com) that has a redirect if it appears to be moving. Although your code takes the same redirect. Now I wonder if it is a code problem or this type of redirect that can not be "deleted"?
Erel B4X founder Staff member Licensed User Longtime User Mar 31, 2014 #6 What exactly is the problem? It returns the wrong status code? Upvote 0
lock255 Well-Known Member Licensed User Longtime User Mar 31, 2014 #7 I returned the original site, but I can not make it display in a webview without being re-directed to the king Mobile ads Upvote 0
I returned the original site, but I can not make it display in a webview without being re-directed to the king Mobile ads
Erel B4X founder Staff member Licensed User Longtime User Mar 31, 2014 #8 Are you downloading the html and then setting it to WebView? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Mar 31, 2014 #10 The line posted above will not affect the WebView in any way. Upvote 0