Solved

How to use Dreamweaver Ultradev to create an ASP login page.

Posted on 2001-07-11
7
513 Views
Last Modified: 2008-02-01
What are the steps involved in creating a login page?  I mean I need specifics here.  I have been to the web site http://www.hiran.desilva.com/ultradev/ where the tutorial is supposed to be absolutely idiot proof.  I must be missing something as it just does not work.  Is there something special to creating an ASP page?  What makes it differ from a file with an html extension?  When the tutorial redirect the user to the page for a correct login it directs them to a xxx.asp file.  What do I put on this page?  I am lost and would really appreciate any help you can give me.  I have read through the tuorial at the above link so many times I almost have it down perfectly.  All the comments say how easy the tutorial is but it is above my head I guess.  Please take me step by painful step so I can get over this password hurdle.

Thank you in advance!

Joe Dunn
0
Comment
Question by:joedunn
7 Comments
 
LVL 33

Expert Comment

by:hongjun
ID: 6275609
The site you provided teaches you how to create a login page step by step. Follow it carefully and you should be able to create one.

You actually can use any editor creating the login page example using Notepad, Visual Interdev, etc.

Difference between htm and html extension
There's simply not much difference between the 2 formats except for the below very insignificant issue. Firstly, the earlier versions of windows like 3.1 supports the 8:3 file format meaning 8 characters file name and 3 characters file extension. If .html is used then there may have some problem. Secondly, although .html posed some inconsistencies in the earlier of windows, it will still be able to display its contents in a browser but links <a href="abc.html"></a> that points to a .html file will not do anything. In general, not really a big issue here.

When to use .htm or .asp?
Simple. If your that file has ASP scripts like <%Response.Write%>, then you need to save the file in .asp extension else use a .htm file. If really unsure, use all in .asp extension.

Post what you have now and any error messages here and we will try to help.

hongjun
0
 
LVL 20

Expert Comment

by:Silvers5
ID: 6275845
How do I control access to an area?

Creating a login for a section of your web site is fairly easy. First, create a login form (loginForm.asp):
 
<form action=loginHandler.asp method=post>
        Username: <input type=text name='username'><BR>
        Password: <input type=password name='password'><BR>
        <input type=submit Value='Log In'><BR>
</form>
 
 
Next, create a login handler (loginHandler.asp):
 
<%
    '---------------------------------------------------------
    '-- check to see that the form was completely filled out--
    '---------------------------------------------------------
    if request.form("username")="" or request.form("password")="" then
        response.redirect("loginForm.asp")
    end if
 
    '---------------------------------------------------------
    '-- open your database connection and check for a record--
    '---------------------------------------------------------
    set conn = server.createObject("ADODB.Connection")
    conn.open "<insert connection string here>"
    u = lcase(request.form("username"))
    p = lcase(request.form("password"))
    sql = "select lin = count(username) from logintable where lower("
    sql = sql & "username)='" & u & "' and lower(password)='" & p & "'"
    set rs = conn.execute(sql)
     
    '--------------------------------------------------------
    '-- Decide whether to let them in --
    '--------------------------------------------------------
    if rs("lin")<>1 then  
        'access Denied
        response.redirect ("loginForm.asp")
    end if
    session("login")=true
    response.redirect ("hiThere.asp")
%>
 
 
Finally, at the top of each page, you test the session variable that you assigned in the script above:
 
<%
    if not session("login") then
        response.redirect("loginForm.asp")
    end if
%>



note that cookies should be enabled on the client.. (they are by default)
0
 

Accepted Solution

by:
usmanbuxi earned 100 total points
ID: 6485093
if u have ultradev4.0 now u can go to this link and would find it very useful http://www.macromedia.com/support/ultradev/building/login_page/

hope it solves your problem..it works for ver 1.0 also
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 33

Expert Comment

by:hongjun
ID: 6485322
Any progresses?

hongjun
0
 
LVL 5

Expert Comment

by:Netminder
ID: 7135410
A request has been made (http://www.experts-exchange.com/cleanup/Q_20320237.html) that this question be closed with the following resolution: split b/w hongjun,Silvers5,usmanbuxi

EXPERTS: Please leave any comment regarding this request here; I will return in seven (7) days to close the question.

Netminder
CS Moderator
0
 
LVL 5

Expert Comment

by:Netminder
ID: 7164016
Per recommendation, force-accepted.

Netminder
CS Moderator

Silvers5: points for you at http://www.experts-exchange.com/jsp/qShow.jsp?ta=asp&qid=20325319
hongjun: points for you at http://www.experts-exchange.com/jsp/qShow.jsp?ta=asp&qid=20325318
0
 
LVL 33

Expert Comment

by:hongjun
ID: 7166787
Netminder, I guess you forgot to force-accept usmanbuxi's comment.

hongjun
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
INNER JOIN ? 8 52
IP API - need data... 4 30
FileUp - Classic ASP 5 24
ASP Classic Query that needs to display more information 18 32
I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:  The Exchange of information …
I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question