📄 myshow.asp
字号:
' reset the cursor to the beginning
If (MM_rs.CursorType > 0) Then
MM_rs.MoveFirst
Else
MM_rs.Requery
End If
' move the cursor to the selected record
MM_index = 0
While (Not MM_rs.EOF And MM_index < MM_offset)
MM_rs.MoveNext
MM_index = MM_index + 1
Wend
End If
%>
<%
' *** Move To Record: update recordset stats
' set the first and last displayed record
Recordset1_first = MM_offset + 1
Recordset1_last = MM_offset + MM_size
If (MM_rsCount <> -1) Then
If (Recordset1_first > MM_rsCount) Then
Recordset1_first = MM_rsCount
End If
If (Recordset1_last > MM_rsCount) Then
Recordset1_last = MM_rsCount
End If
End If
' set the boolean used by hide region to check if we are on the last record
MM_atTotal = (MM_rsCount <> -1 And MM_offset + MM_size >= MM_rsCount)
%>
<%
' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters
Dim MM_keepNone
Dim MM_keepURL
Dim MM_keepForm
Dim MM_keepBoth
Dim MM_removeList
Dim MM_item
Dim MM_nextItem
' create the list of parameters which should not be maintained
MM_removeList = "&index="
If (MM_paramName <> "") Then
MM_removeList = MM_removeList & "&" & MM_paramName & "="
End If
MM_keepURL=""
MM_keepForm=""
MM_keepBoth=""
MM_keepNone=""
' add the URL parameters to the MM_keepURL string
For Each MM_item In Request.QueryString
MM_nextItem = "&" & MM_item & "="
If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then
MM_keepURL = MM_keepURL & MM_nextItem & Server.URLencode(Request.QueryString(MM_item))
End If
Next
' add the Form variables to the MM_keepForm string
For Each MM_item In Request.Form
MM_nextItem = "&" & MM_item & "="
If (InStr(1,MM_removeList,MM_nextItem,1) = 0) Then
MM_keepForm = MM_keepForm & MM_nextItem & Server.URLencode(Request.Form(MM_item))
End If
Next
' create the Form + URL string and remove the intial '&' from each of the strings
MM_keepBoth = MM_keepURL & MM_keepForm
If (MM_keepBoth <> "") Then
MM_keepBoth = Right(MM_keepBoth, Len(MM_keepBoth) - 1)
End If
If (MM_keepURL <> "") Then
MM_keepURL = Right(MM_keepURL, Len(MM_keepURL) - 1)
End If
If (MM_keepForm <> "") Then
MM_keepForm = Right(MM_keepForm, Len(MM_keepForm) - 1)
End If
' a utility function used for adding additional parameters to these strings
Function MM_joinChar(firstItem)
If (firstItem <> "") Then
MM_joinChar = "&"
Else
MM_joinChar = ""
End If
End Function
%>
<%
' *** Move To Record: set the strings for the first, last, next, and previous links
Dim MM_keepMove
Dim MM_moveParam
Dim MM_moveFirst
Dim MM_moveLast
Dim MM_moveNext
Dim MM_movePrev
Dim MM_urlStr
Dim MM_paramList
Dim MM_paramIndex
Dim MM_nextParam
MM_keepMove = MM_keepBoth
MM_moveParam = "index"
' if the page has a repeated region, remove 'offset' from the maintained parameters
If (MM_size > 1) Then
MM_moveParam = "offset"
If (MM_keepMove <> "") Then
MM_paramList = Split(MM_keepMove, "&")
MM_keepMove = ""
For MM_paramIndex = 0 To UBound(MM_paramList)
MM_nextParam = Left(MM_paramList(MM_paramIndex), InStr(MM_paramList(MM_paramIndex),"=") - 1)
If (StrComp(MM_nextParam,MM_moveParam,1) <> 0) Then
MM_keepMove = MM_keepMove & "&" & MM_paramList(MM_paramIndex)
End If
Next
If (MM_keepMove <> "") Then
MM_keepMove = Right(MM_keepMove, Len(MM_keepMove) - 1)
End If
End If
End If
' set the strings for the move to links
If (MM_keepMove <> "") Then
MM_keepMove = Server.HTMLEncode(MM_keepMove) & "&"
End If
MM_urlStr = Request.ServerVariables("URL") & "?" & MM_keepMove & MM_moveParam & "="
MM_moveFirst = MM_urlStr & "0"
MM_moveLast = MM_urlStr & "-1"
MM_moveNext = MM_urlStr & CStr(MM_offset + MM_size)
If (MM_offset - MM_size < 0) Then
MM_movePrev = MM_urlStr & "0"
Else
MM_movePrev = MM_urlStr & CStr(MM_offset - MM_size)
End If
%>
<HTML>
<HEAD>
<TITLE>未标题-1</TITLE>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=gb2312">
<link href=../images/k.css rel=stylesheet>
<style type="text/css">
<!--
.mm_botton{
border-top: #c4cccc 3px double;
border-right: #acb5b5 3px double;
border-bottom: #6f7777 3px double;
border-left: #acb5b5 3px double;
background: url(../images/background_form_element.gif) #fefefe repeat-x;
font:12px tahoma;
padding-top:3px;
padding-bottom:4px;
padding-left:3px;
padding-right:4px;
text-decoration: none;
color:#666666;
}
.mm_botton:link{
color:#666666;
}
.mm_botton:hover{
border-top: #aedf9a 3px double;
border-right: #94da78 3px double;
border-bottom: #6ab94b 3px double;
border-left: #94da78 3px double;
text-decoration:none;
color:#999999;
}
body {
background-image: url(../images/bg.gif);
}
.style1 {
font-size: 12px;
color: #000000;
}
.style3 {color: #000000}
body,td,th {
font-size: 12px;
color: #000000;
}
-->
</style>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_validateForm() { //v4.0
var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
if (val) { nm=val.name; if ((val=val.value)!="") {
if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an e-mail address.\n';
} else if (test!='R') { num = parseFloat(val);
if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
min=test.substring(8,p); max=test.substring(p+1);
if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
} } } else if (test.charAt(0) == 'R') errors += '- '+nm+' is required.\n'; }
} if (errors) alert('The following error(s) occurred:\n'+errors);
document.MM_returnValue = (errors == '');
}
//-->
</script>
</HEAD>
<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<!-- ImageReady Slices (未标题-1) -->
<TABLE WIDTH=498 height="220" BORDER=0 CELLPADDING=0 CELLSPACING=0>
<TR align="center" valign="middle">
<TD height="13" COLSPAN=3><div align="center"><span class="style1">.....................................................................................</span></div></TD>
</TR>
<TR>
<TD width="133" align="center" valign="top"><img src="../images/myshow.gif" width="133" height="200"> </TD>
<TD width="353" colspan="2" align="left" valign="top">
<form name="form1" method="POST" action="<%=MM_editAction%>">
<table width="358" border="0">
<tr class="style3">
<td width="71" align="right" valign="baseline" scope="col"><span class="style3">用户名:</span></td>
<td width="275" scope="col"><span class="style3">
<%=(Recordset1.Fields.Item("dengluming").Value)%> </span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">年龄:</span></td>
<td><span class="style3">
<input name="nl" type="text" id="nl" value="<%=(Recordset1.Fields.Item("nianling").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">性别:</span></td>
<td><span class="style3">
<select name="xb" id="xb">
<option value="男" <%If (Not isNull((Recordset1.Fields.Item("dengluming").Value))) Then If ("男" = CStr((Recordset1.Fields.Item("dengluming").Value))) Then Response.Write("SELECTED") : Response.Write("")%>>男</option>
<option value="女" <%If (Not isNull((Recordset1.Fields.Item("dengluming").Value))) Then If ("女" = CStr((Recordset1.Fields.Item("dengluming").Value))) Then Response.Write("SELECTED") : Response.Write("")%>>女</option>
</select>
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">密码:</span></td>
<td><span class="style3">
<input name="ma" type="password" id="ma" value="<%=(Recordset1.Fields.Item("mima").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">单位:</span></td>
<td><span class="style3">
<input name="dw" type="text" id="dw" value="<%=(Recordset1.Fields.Item("danwei").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">QQ:</span></td>
<td><span class="style3">
<input name="qq" type="text" id="qq" value="<%=(Recordset1.Fields.Item("qq").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">电子邮箱或MSN:</span></td>
<td><span class="style3">
<input name="mail" type="text" id="mail" value="<%=(Recordset1.Fields.Item("mail").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">电话:</span></td>
<td><span class="style3">
<input name="tel" type="text" id="tel" value="<%=(Recordset1.Fields.Item("tel").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">密码问题:</span></td>
<td><span class="style3">
<input name="mat" type="text" id="mat" value="<%=(Recordset1.Fields.Item("mimawenti").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">密码答案:</span></td>
<td><span class="style3">
<input name="mad" type="text" id="mad" value="<%=(Recordset1.Fields.Item("mimahuida").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">真实姓名:</span></td>
<td><span class="style3">
<input name="xm" type="text" id="xm" value="<%=(Recordset1.Fields.Item("xingming").Value)%>">
</span></td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3">头像:</span></td>
<td><input name="face" type="hidden" id="您的头像" value="<%=(Recordset1.Fields.Item("face").Value)%>">
<a href=### onclick=window.open("face.asp","face","width=400,height=400,resizable=1,scrollbars=1") title=点击选择头像> <img src="<%=(Recordset1.Fields.Item("face").Value)%>" border=0 id="faceImg"></a> 点击设置您的头像 </td>
</tr>
<tr class="style3">
<td align="right" valign="baseline"><span class="style3"></span></td>
<td><span class="style3">
<input name="Submit" type="submit" class="mm_botton" onClick="MM_validateForm('dlm','','R','nl','','RinRange0:99','ma','','R','dw','','R','qq','','RisNum','mail','','RisEmail','tel','','RisNum','mat','','R','mad','','R','xm','','R');return document.MM_returnValue" value="更新">
<input name="Submit" type="reset" class="mm_botton" value="重置">
</span></td>
</tr>
</table>
<input type="hidden" name="MM_update" value="form1">
<input type="hidden" name="MM_recordId" value="<%= Recordset1.Fields.Item("id").Value %>">
</form>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -