You didn't read the second paragraph of the comment you replied to-- which explained this exact issue before you replied "no":
> You don't see this with curl/wget because they use user agent sniffing. If they don't think you're a browser they _will_ give you a Location header. To see it, capture a request in Firefox developer tools, right click on the request, copy as CURL.