Welcome to WebmasterWorld Guest from 54.167.175.157

Forum Moderators: brotherhood of lan & mack

prevent bookmarking

   
8:26 am on Aug 13, 2004 (gmt 0)

10+ Year Member



how do i prevnt some from bookmark a page in asp or vb script?
8:39 am on Aug 13, 2004 (gmt 0)

WebmasterWorld Senior Member topr8 is a WebmasterWorld Top Contributor of All Time 10+ Year Member



you can't stop someone bookmarking a page.
10:12 am on Aug 13, 2004 (gmt 0)

10+ Year Member



you could give the url some kind of session id which expires after a certain amount of time.
10:23 am on Aug 13, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



how do i prevnt some from bookmark a page in asp or vb script?

Why?

10:38 am on Aug 16, 2004 (gmt 0)

10+ Year Member



Hi!

The problem is that pages after the login page is been bookmarked. Want I need to happen,is to make all pages after the login page unattainable, so if a user needs to view a page he would have to login again.

Can it be done?

10:52 am on Aug 16, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Want I need to happen,is to make all pages after the login page unattainable, so if a user needs to view a page he would have to login again.

Per se bookmarking is totally under control of the end user - you can have some funny games with POST requests which are hard (if possible) to bookmark, but this is not good way of solving your problem.

If you want to allow access to only authenticated users then your pages after login page should check for login cookie(s) set by the login page, if cookie(s) not set then ask to login then show content relevant to the page originally requested.

11:34 am on Aug 16, 2004 (gmt 0)

10+ Year Member



Can this be done in asp?
And it wud not be necessary for the browser to allow session cookies?
11:56 am on Aug 16, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yes it can be done in ASP, the logic can be pretty simple:

1. login page - check username/password against database of allowed users, and if all matched then set cookie that will indicate that this user is authorised.

2. content page - if cookie is not set, then redirect to login, otherwise show content.

2:44 pm on Aug 16, 2004 (gmt 0)

10+ Year Member



Thanks.
I'll try it out, and c if it works.
7:56 pm on Aug 25, 2004 (gmt 0)

10+ Year Member



or you could try the apache .htaccess files (if your server runns apache - probably dosn't since your in to asp)
 

Featured Threads

Hot Threads This Week

Hot Threads This Month