Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PHP Location Header Ignore Hash [duplicate]

Possible Duplicate:
URL Fragment and 302 redirects

I am integrating Facebook login into my site. When Facebook redirects to my site with the code query parameter, there is a hash at the end http://myurl.com/code=xxx#_=_ When I then redirect from this url to another url at my site:

header('Location: http://myurl.com/home');

It keeps the hash tag and ends up as http://myurl.com/home#_=_

Is there a way to redirect without the hash or if anyone is familiar with Facebook a way to get it to stop adding the hash in the first place?

like image 490
chris Avatar asked Sep 07 '11 18:09

chris


1 Answers

You can redirect on your server side PHP to a URL that includes its own hash. That's what I had to do a ruby app that uses backbone.js.

PS - I specified the redirect_uri and FB still appended the stupid #_=_ string :/

like image 92
Brenden Avatar answered Oct 01 '22 22:10

Brenden