Archived Forum Post

Index of archived forum posts


FinalRedirectUrl is empty after 303 redirect

Nov 21 '16 at 10:18


I'm using the latest C# x64 HttpClient After sending POST request I'm reciving 303 redirect. Chilkat follows this redirect but the FinalRedirectUrl is empty (also WasRedirected is false)

---- Received ----
HTTP/1.1 303 See other
Date: Sat, 19 Nov 2016 22:21:07 GMT
Content-Type: text/html; charset=utf-8
Content-Length: 0
Connection: keep-alive
Server: Apache/2

---- Sending ----
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:36.0) Gecko/20100101 Firefox/36.0
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Encoding: gzip,deflate,sdch
Cookie: 26ff1c4cf8034b8d6fbfabd99c91a505=1e519806c70318a5a3dffe0d1fc98d88


Thanks. I'd need to see the contents of the verbose LastErrorText for the method call that sends the POST. (For verbose, set the VerboseLogging property = true.)


After more investigation I have noticed that the problem is another. When I've send POST request and then recive 303 header chilkat redirects to new location and resends all POST data as GET requests. That page recives it and doing action one more time sends 303 one more time, chilkat redirect to new location with POST data as GET... and again and again until reaches max redirects. Chilkat finish at 303 page and FinalRedirectUrl is empty.

So for conclusion - after POST and reciving redirect chilkat should follow Location but don't send that data again? It is like browsers work - they send data and than doing simple GET request wihout data. At the moment I'm cleaning HttpRequest with OnRedirect method - but maybe this will be changed in chilkat?