Recently, Web SQL Injection attacks, JS scripts, and HTML scripts appear to be more intense. many websites are plagued by such attacks. They are not immediately repaired as they do with host vulnerabilities. WEB attacks make us very inconvenient to
The code is as follows:Copy code add a new node to xml Addok = request ("addok ")If addok = "" Or IsNull (addok) Then%>Website name: Address: End IfIf addok = "add" thenSite = request ("site ")Url = request ("url ")StrSourceFile = Server.
Audit is the monitoring and recording of selected user actions. It is usually used:
U reviews suspicious activities. For example, if the data is deleted by an unauthorized user, the security administrator may decide to audit all connections to the
Editbook. asp
1. The input parameter ID is used to modify the subscript position of the node in the XML file.
Id = request ("ID ")
If isnumeric (ID) = false or isnull (ID) then
Response. Write ("the parameter is incorrect. Please return it!
untitled document
Set Rs=server.createobject ("Adodb.recordset")
On Error Resume Next
Sql= "SELECT * from Your_table"
Rs. Open SQL, Conn
Rsname=rs (0). Name
For i = 1 to RS. Fields.count-1
' RSNAME=RSNAMECHR (9) &rs (i). Name
rsname=rsname& ","
Recently, some sites were found to be vulnerable to UBB Cross-site scripting attacks. Cross-site scripting attacks are rarely a significant impact on the server, but for a site, this vulnerability is too unworthy! Small, play point what dongdong
Common syntax and functions of #TITLE =asp#INFOSome common syntax and custom functions of ASP#SORT =n
#T = ===asp commonly used grammar = = =#T =============================#T = Database Related#T = Connect to an Access databaseDim
Presumably you'll use JavaScript to randomly display pictures. But if the image of the data (such as links) is often changed, or by the user modified, increased, how to do? I have a way here.Put the picture information (such as name, address, link,
' Excela.vbs ' directly to query the results of the data generated EXCEL table, a little modification can be
' Change to ASP file on server to customer
Option Explicit
Dim conn,strconnstring
Set conn = WScript.CreateObject ("ADODB. Connection ")
On
Skill
1. Several common functions
Round (pi, 2) roundedFormatNumber (k,4) ' formats K as a number with four-bit decimal points.eg. If K =20000 is shown as 20,000.00 if FormatNumber (k,0) is 20,000Replace (Expression,find,replacewith) ' returns a
Copy Code code as follows:
'=====================================
' Convert content to prevent accidental
'=====================================
Function Content_encode (ByVal t0)
IF IsNull (t0) Or Len (t0) =0 Then
Content_encode= ""
Else
IP filtering restriction function in ASP
' Get the visitor's address
Ip=request.servervariables ("REMOTE_ADDR")
' The allowed IP address segment is 10.0.0.0~10.68.63.255
allowip1= "10.0.0.0"
Allowip2= "10.68.10.71"
Response.Write Checkip (IP,ALLOWIP1
Copy Code code as follows:
'==============================
' Feature Description: Remove HTML tags with regular
' Cannot keep and so on and user-defined
'==============================
Function Removehtmltag (fstring)
Dim RE
Set re =
One, Web server security
PHP is nothing but a Web server module function, so first of all to ensure the security of the Web server. Of course, the Web server to be secure and must first ensure that the system security, so it is far, endless. PHP
Check.asp
Copy Code code as follows:
''''''''''''''''''''''''''''''''''''
Function ReplaceText (FSTRING,PATRN,REPLSTR)
Set regEx = New RegExp ' establishes a regular expression.
Regex.pattern = Patrn ' Set mode.
Regex.ignorecase =
'**************************************************
' Function name: Createkeyword
' Function: Generate keywords from a given string
' Parameters: Constr---The original string to generate the keyword
' Return value: the generated keyword
'***********
'==================================================
' Function name: Fphtmlencode
' Function: Title filter
' Parameter: fstring------string
'==================================================
Function Fphtmlencode (fstring)
If IsNull (fstring)
'================================================
' Function name: Replacetrim
' Function: Filter out all tab and carriage returns and newline in characters
'================================================
Public Function Replacetrim (ByVal
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.