tag:blogger.com,1999:blog-5868304829880692455.post2733809358379987659..comments2023-09-03T23:17:25.260+08:00Comments on Mr.J4mes' Programming Wonderland: [How To] - Redirect to original page after login in JSFJames Tranhttp://www.blogger.com/profile/06350623399905315708noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-5868304829880692455.post-36520050837264277632013-11-01T15:02:50.415+08:002013-11-01T15:02:50.415+08:00I think the simplest solution would be not to incl...I think the simplest solution would be not to include the "" in any pages that do not require redirecting to. For instance, the Login page should not contain the event. The effect is that no "originalURL" will be captured.James Tranhttps://www.blogger.com/profile/06350623399905315708noreply@blogger.comtag:blogger.com,1999:blog-5868304829880692455.post-10973585721925022342013-08-15T00:21:51.575+08:002013-08-15T00:21:51.575+08:00Thanks for posting this. I've been wanting to ...Thanks for posting this. I've been wanting to switch to container based authentication but really don't have time. Your post has allowed me to tweak my existing filter based authentication to redirect users to the URL they initially tried to visit.<br /><br />I do have a problem when people try to visit http://example.com/myapp. This takes them to the login page if they aren't already logged in. But the originalURL is set to /myapp/ so they get taken back to the login page even after a successful login. After they login a second time, they are taken to the welcome page. I'm trying to figure out a tidy way to avoid this, probably by adding some extra checks in my filter class, for instance by checking that requestURI != contextPath (plus an extra slash).Carlhttps://www.blogger.com/profile/05826721717416529283noreply@blogger.comtag:blogger.com,1999:blog-5868304829880692455.post-61623982764283243002013-06-08T18:12:37.477+08:002013-06-08T18:12:37.477+08:00SocialAuth will generate a proper link for you to ...SocialAuth will generate a proper link for you to redirect the user to for logging in. I think you should try to print out the link to debug :)... And sorry, at the moment, I'm a bit busy. Please upload your WAR to some repository and leave the link here. I will take a look when I have more spare time :D...James Tranhttps://www.blogger.com/profile/06350623399905315708noreply@blogger.comtag:blogger.com,1999:blog-5868304829880692455.post-31990154626544450132013-06-07T22:33:57.573+08:002013-06-07T22:33:57.573+08:00I am using the same example of using socialauth fo...I am using the same example of using socialauth for facebook login for jsf web application. However i am not able to execute the application successfully because of the below issue.<br />{<br /> "error": {<br /> "message": "redirect_uri isn't an absolute URI. Check RFC 3986.",<br /> "type": "OAuthException",<br /> "code": 191<br /> }<br />}<br /><br />Please help me in resolving this issue. Provide me your mail id to send the complete WAR file for you to look intoAnonymousnoreply@blogger.com