Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

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

Posted on 2001-07-11
7
Medium Priority
?
518 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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:Michel Sakr
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 400 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
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
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

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

670 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