How do I have to escape ampersands in URLs when lo

2019-07-04 11:27发布

Well actually I know, that I should replace & by %26

But I'm using this URL to log in with OpenID:

https://innubili-gidea.appspot.com/_ah/login_redir?claimid=https://www.google.com/accounts/o8/site-xrds?hd=icada.com&continue=https://innubili-gidea.appspot.com/%3Fdomain%3Dicada.com%26campaign%3D2%26

Login Link

As you can see, the continue parameter is properly escaped.

But after being redirected through Googles login pages, it redirects me back to

https://innubili-gidea.appspot.com/?domain=icada.com

So the &campaign=2 parameter is missing

Link after Login

Can you confirm, that I escaped the continue parameter correctly?

For then it looks to me as this seems to be an issue at Googles login.

2条回答
Lonely孤独者°
2楼-- · 2019-07-04 11:30

You are correctly escaping the Url, and yes, this is a well-known issue.

查看更多
对你真心纯属浪费
3楼-- · 2019-07-04 11:44

I just found out it works, if I escape the ampersand twice.

& -> %26 -> %2526
查看更多
登录 后发表回答