How to Merge ASP With HTML

By eHow Computers Editor

Rate: (1 Ratings)

Merging ASP and HTML enables you to create a dynamic website with a wealth of information. Below is an illustration of how to create an ASP page for classic ASP and ASP.NET 2.0 that show the login credentials of a user.

Instructions

Difficulty: Moderately Challenging

Step1
Write the programming language you will use for the ASP code. Your options are VBScript, JavaScript and VB or C# for ASP.NET.

Classic ASP
<%@Language="VBSCript,"

ASP.NET
<%@Page Language="VB," %>
Step2
Name the HTML Header and part of BODY section
<HTML>
<HEAD>
<TITLE>Login Page</TITLE>
</HEAD>
Step3
Begin the BODY section

<BODY BGCOLOR="White" TOPMARGIN="10" LEFTMARGIN="10">

<FONT SIZE="4" FACE="ARIAL, HELVETICA">
<B>Login Page</B></FONT><BR>

<HR SIZE="1" COLOR="#000000">
Step4
Put ASP code within the HTML text
<!--Display LOGON_USER Server variable. -->

You logged in as user:<B> <%= Request. ServerVariables ("LOGON_USER") %></B>

<!--Display AUTH_TYPE Server variable. -->

<P>You were authenticated using:<B> <%= Request.ServerVariables("AUTH_TYPE")%></B> authentication. </P>
Step5
Insert the closing Tags for BODY and HTML
</BODY>
</HTML>
Step6
Save the file. Use .asp for classic ASP file and .aspx for ASP.NET file.
e.g UserCredential.asp or UserCredential.aspx

Tips & Warnings

  • <% %> is a pair of tags. They are used to specify a code section as an ASP code.
  • From classic ASP to ASP.NET 2.0, there are several versions of ASP and they all require similar steps when merging ASP code and HTML text.

Post a Comment

POST A COMMENT

Request a New How-To Article

Looking for more How To information? Chances are there’s an eHow member who knows how to do what you’re looking to do. Submit an article request now!

eHow Article: How to Merge ASP With HTML

eHow Computers Editor

eHow Computers Editor

Category: Computers

Articles: See my other articles

Related Ads