Last post Nov 30, 2016 06:28 PM by PatriceSc
Nov 30, 2016 05:16 PM|Gaston Leblanc|LINK
Suppose one of my website pages has a video. The page itself is in a folder with a web.config that says only a few select users can use the pages in that folder. The user watches the video, then takes a nap, then returns to the screen. He clicks a button.
But during his nap, the site as logged out. So membership takes him to a log in page . He logs in, and then membership is smart enough to take him to the same page.
The hitch is, that he should not be able to get to that page without going through a series of other pages first - other pages that build a data structure or set a session variable or prepare a database.
So he gets an error message.
I have many pages where this error could happen.
Is there any simple way to say if membership logged out, then after log-in "do not go to any page but the home page?" Or better yet - go to a page which has an explanatory message?
Nov 30, 2016 06:28 PM|PatriceSc|LINK
Are you able to rebuild easily the needed structure without any user intervention.
If not you could check for that structure and then redirect to the page that starts this building process. Or just ignore the returnurl and return to a fixed page ?
If yes, you could access that through something such as http://foxsys.blogspot.fr/2007/01/session-facade-aspnet-c.html#!/2007/01/session-facade-aspnet-c.html and
you could then "rebuild" automatically what you need if it is missing.