Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Form Validation

nomi85nomi85 Member Posts: 7
I am using a form validation in ASP. I made a simple html form in which i take input from user his name,password,confrim password and full name and while submitting i call an asp file in which i request all the feilds from the html form.
In this asp page i validate the username that it exists or not .Can i also validate that password and the confirm password is same or not.


  • bagles1bagles1 Member Posts: 54
    Yes this is easily done. However, I think you will find that it is much easier to validate all the information in JavaScript because it can be done before the form is posted. However, if you are only wanting to find out how to do it in ASP I just answered this questions a couple of questions down. The way I read your question was basically validating that the user has input something in the user name field and that the passwords equal each other. If this is the case then this simple script would work.

    if trim(request.form("username")) = "" then
    ' username was empty or not filled in
    end if
    if request.form("password") <> request.form("confirmpassword") then
    ' passwords did not match
    end if


  • Andre YoungAndre Young USAMember Posts: 0

    ______ // // free ebooks and video tutorials about / Delphi C# PL/SQL Python R Visual Basic C++ MATLAB Visual Basic .NET JavaScript Swift PHP Objective-C Scratch Java Go Ruby Assembly Perl C Scala F# Alice Apex Prolog Kotlin ML Hack VBScript ABAP Scheme Erlang Lua Awk D Dart Rust COBOL Crystal Clojure Bash Transact-SQL Logo LabVIEW Lisp Ada SAS FoxPro Fortran Julia / ____________

Sign In or Register to comment.