ASP Full Lecture

Source: Internet
Author: User
ASP whole Lecture ~ ~ Hehe


hehe ~ Summer vacation, I want crazy post! ...-%¥% ...... ¥¥#......-*


for our flash, a little learn to learn ASP it ~ (endure it ~) because this thing actually uses is quite big. or to log in as an example to explain. This time, we use ASP, so with the action of flash contrast more clearly, I also try to do the basic agreement between the two, the advantages of ASP also on the dew point! ^_^


Sorry, first of all, must be on the ASP's Grammar class. Hey, the study is also good ah don't throw things up! )


because the ASP is using VB Script and Jscript, so the ASP format has <% and%&GT, the simplest combination scripts

The
method.


 


first to mention a contact with the example, familiar with:


<html>


<head><title>hello world</title></head>


<body>


<%


Response.Write ("Hello world!")


%>


</body>


</html>


above is one of the simplest Hello world examples, his role is to output a word to the browser Hello World, you can see in fact, the ASP only used a sentence, that is, <% Response.Write ("Hello world!")% >. Here the response is one of the basic five objects of ASP, in fact Response.Write and JavaScript document.write functions are the same-are output to the browser. As for HTML I guess I don't want to say it ~ ~


OK, I will say the following detailed ASP five objects, these things can do the site commonly used things oh ~ like questionnaires, counters, password verification, dynamic collection of user information, etc., how, echocardiography? Oh ~


start with response.


 


1. Response.Write


most commonly used is that we use the Response.Write, this thing will let the browser output. Because it is commonly used, so the old man was simplified by gates =.


That means <% Response.Write ("Hello world!")%> can be abbreviated to <% = ("Hello World")%>.


 


2. Response.Redirect


This is our common site steering function. Note that you must not output anything to the browser before Response.Redirect, (including HTML, of course) because Response.Redirect is the command to let the browser move, and Response.Write or HTML is to let the browser do something else, which creates a conflict.


 


syntax is simple: Response.redirec "AB";


here AB is the page you want to turn to *.htm (asp,swf,,jsp,php ... )"


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.