This article mainly introduces the asp.net send the mail sample sharing, the need friend can refer to the following Mailhelper -------Mail help class code is as follows: using System; Using System.Collections.Generic; Using System.Linq; Using
This article mainly describes the ASP.net disable page caching method, the need for friends can refer to the following 1, in the ASP page header The first 3 types just empty the cache, that is, temporary files stored in the Temporary Internet
This article introduces asp.net to get the screenshot of the site's example code, the need for friends can refer to the
copy code code as follows:
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data;
The following code is an ASP generated image verification code program Oh, about the validation code to write the program most will know Oh, let's look at this picture verification code generation way bar.
Option Explicit response.buffer=true
in writing asp.net applications, sometimes in order to better control the path of static files, such as in the template page or user control set JS or CSS file path, etc., using absolute path is unavoidable. Here are a few ways to get an absolute
Reduce server burden, ASP Prevent Web page refresh code
Sub preventrefresh ()
dim ref reshtime,isrefresh
RefreshTime = 10 ' Prevent refresh time, in seconds
isRefresh = 1 ' use anti-
NextRecordset and GetRows are two attributes of the recordset to improve the speed of the batch query is very effective, you may use very little, share the use of these two methods:
GetRows Method: The recordset Recordset is extracted into a
The ASP Application object is used to share information between all users of a specific aspapplication program. All ASP files are part of a virtual directory in IIS, the same aspapplication program.
The Application.Contents collection contains all
Let's take a look at the example tutorial below.
First take a look at the submitted page:
Here's a look at the page that receives the data and saves it.
Set fs = CreateObject ("Scripting.FileSystemObject")Folderpath=server.mappath ("") &
Global.asa is a text file found in your home directory (/Global.asa). Lou shows the basic extructure a Global.asa file.
Global.asa
The file will be activated in this case:
When the first visitor visits our web pageWhen the new session starts.In
Class cls_fun private x,y,ii ============================== function name: Alertinfo use: Error display function parameter number: Error hint content infostr, turn page Gourl ============= ================= public Function
Class cls_db private connstr private dbpath,dblink,dbi ============================ = = Function name: Db_conn for use: Database connection function parameter number: ======== ====================== private Sub db_conn ()
Use the following methods:
Program codeDim Arr:set arr=new ArrayListArr.add "a": Arr.add "B": Arr.add "C"Response.Write Arr.count & ""For I=0 to Arr.count-1Response.Write Arr.item (i) & ""NextSet arr=nothing%>
Class ArrayList Private M_array ()
Function Isinteger (para) on Error Resume Next Dim str Dim l,i If ISNULL (para) then isinteger=false Exit Function End If STR=CSTR (para) if trim (str) = "Then
Write in web.config:
~/index.html//Request for Change page~/index.aspx//without parameters
~/help/newpro (d*) .html//(d*) representing parameters~/Help/newPro.aspx?pNum=$1//There is a parameter in the case
~/help/aboutjianghujia (d*) _ (d*)
In For Each ... Next loop like, for ... Next loop. Rather than the specified number of repeated statements,
Every name ... Next loops a repeating collection of objects (or each item) for each element in the array.
The following code fragment
This article mainly introduces how to achieve the asp.net background window, the need for friends can refer to the nextGeneral Bullet window code is as follows: Page.ClientScript.RegisterStartupScript (this. GetType (), "message", "alert (' OK
This article introduces the ASP.net JS take the master page control value of the simple method, the need for friends can refer to the
copy code code as follows:
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