Page passwords

B

Bob

I want to put several links on a page where once you click
on that link (to another page on the same site), you force
the user to enter a secure password before the page
opens. Each of 10 different links (different pages) would
need it's own secure password.

Thanks.
 
K

Kevin Spencer

Okay, so, what's the question?

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
R

Roger

One way would be to create 10 different subwebs with unique permissions.
Put the pages in these subwebs (actually you could have several pages in
each subweb). When user clicks a link they will have to enter username pw
to get in.

Roger Sipson
 
C

clintonG

Each of the 10 links will include a QueryString value, i.e.

requestedpage.asp?pswdtype=01
requestedpage.asp?pswdtype=02
requestedpage.asp?pswdtype=03
....

Part 1:
When requestedpage.asp is loaded, a script ensures that the request
to load requestedpage.asp came from a click on a link from the page
used to request and load requestedpage.asp. That would be done
using Request.ServerVariables("HTTP_REFERER"). This prevents
requestedpage.asp from being loaded by typing its URL into the
browser or by recalling requestedpage.asp as a saved Favorite.
If the HTTP_REFERER variable is empty redirect to sorrycharlie.asp.

Part 2:
Once the HTTP_REFERER is validated the script uses the
Request.QueryString method to get the QueryString values such as
01, 02, 03 and so on where each value is a symbolic 'rule' that your
script will 'know' how to determine which secure password is required
to continue loading requestedpage.asp and which users are permitted
to log into requestedpage.asp using a user name and password. A
database is generally required to achieve this latter part of the process.

That's the basics I've used for my customers who needed this type of
functionality on the e-commerce sites I've coded for. Its somewhat
common for membership systems and sites that required different levels
of access for different business partners.


--
<%= Clinton Gallagher
A/E/C Consulting, Web Design, e-Commerce Software Development
Wauwatosa, Milwaukee County, Wisconsin USA
NET csgallagher@ REMOVETHISTEXT metromilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/
 
R

Roger

Sounds like a nice solution if your server supports asp. If you are on a
low-cost linux server then what do you do?? Will this still work using
javascript?

Roger
 
C

clintonG

PHP is the defacto scripting language supported on Linux platforms
and is -- generally speaking --functionally equivalent to Microsoft's
ASP.

Netscape modified JavaScript to run on the server but I don't think
it gained much support by those developing the application servers
such as Apache or IIS. You can research it of course....

Google: "server-side"+"javascript"

IMO the wisest long term strategy suggests learning C# as *all*
web development requires mastery in client-side JavaScript
and both C# and JavaScript are nearly equivalent. Furthermore, the
Mono Project now allows ASP.NET (web) applications to run
on Linux. C# and Java are also nearly equivalent noting the
equivalency I am referring to entails syntax and grammar. Thus,
learning C# enables a developer to extend their efforts to a
broader scope of influence.

<%= Clinton Gallagher
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top