<ASP>有没有人能帮我看下这段代码,帮我解释一下啊!我是新手啊!看不懂!
<%'***InsertRecord:setvariablesIf(CStr(Request("MM_insert"))="form1")ThenMM_editConne...
<%
' *** Insert Record: set variables
If (CStr(Request("MM_insert")) = "form1") Then
MM_editConnection = MM_connMamber_STRING
MM_editTable = "Customers"
MM_editRedirectUrl = "Complete"
MM_fieldsStr = "txtID|value|txtName|value|txtPWS|value|radiobutton|value|txtBirthday|value|txtE-MAIL|value|txtPhone|value|txtFax|value|txtCity|value|txtAddress|value"
MM_columnsStr = "CustomerID|none,none,NULL|CustomerName|',none,''|PSW|',none,''|Sex|',none,''|Brithday|',none,NULL|E-MAIL|',none,''|Phone|none,none,NULL|Fax|none,none,NULL|City|',none,''|Address|',none,''"
' create the MM_fields and MM_columns arrays
MM_fields = Split(MM_fieldsStr, "|")
MM_columns = Split(MM_columnsStr, "|")
' set the form values
For MM_i = LBound(MM_fields) To UBound(MM_fields) Step 2
MM_fields(MM_i+1) = CStr(Request.Form(MM_fields(MM_i)))
Next
' append the query string to the redirect URL
If (MM_editRedirectUrl <> "" And Request.QueryString <> "") Then
If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0 And Request.QueryString <> "") Then
MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString
Else
MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString
End If
End If
End If
%> 展开
' *** Insert Record: set variables
If (CStr(Request("MM_insert")) = "form1") Then
MM_editConnection = MM_connMamber_STRING
MM_editTable = "Customers"
MM_editRedirectUrl = "Complete"
MM_fieldsStr = "txtID|value|txtName|value|txtPWS|value|radiobutton|value|txtBirthday|value|txtE-MAIL|value|txtPhone|value|txtFax|value|txtCity|value|txtAddress|value"
MM_columnsStr = "CustomerID|none,none,NULL|CustomerName|',none,''|PSW|',none,''|Sex|',none,''|Brithday|',none,NULL|E-MAIL|',none,''|Phone|none,none,NULL|Fax|none,none,NULL|City|',none,''|Address|',none,''"
' create the MM_fields and MM_columns arrays
MM_fields = Split(MM_fieldsStr, "|")
MM_columns = Split(MM_columnsStr, "|")
' set the form values
For MM_i = LBound(MM_fields) To UBound(MM_fields) Step 2
MM_fields(MM_i+1) = CStr(Request.Form(MM_fields(MM_i)))
Next
' append the query string to the redirect URL
If (MM_editRedirectUrl <> "" And Request.QueryString <> "") Then
If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0 And Request.QueryString <> "") Then
MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString
Else
MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString
End If
End If
End If
%> 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询