<!--#include file="conn.asp"-->
<%if not isnumeric(request("id")) and request("id")<>"" then
Response.Redirect"info.asp?info=ID必须是数字"
response.end
end if
if request("id")="0" or request("id")="" then
Response.Redirect"info.asp?info=对不起，您输入错误的ID"
response.end
end if%>
<%
sql="select * from desktop where Desktopid="&request.querystring("id")
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,3
rs("DesktopCk")=rs("DesktopCk")+1
rs.update
if rs.eof and rs.bof then
rResponse.Redirect"info.asp?info=错误的ID!"
end if%>
<SCRIPT language=JavaScript>
drag = 0
move = 0
function init() {
    window.document.onmousemove = mouseMove
    window.document.onmousedown = mouseDown
    window.document.onmouseup = mouseUp
    window.document.ondragstart = mouseStop
}
function mouseDown() {
    if (drag) {
        clickleft = window.event.x - parseInt(dragObj.style.left)
        clicktop = window.event.y - parseInt(dragObj.style.top)
        dragObj.style.zIndex += 1
        move = 1
    }
}
function mouseStop() {
    window.event.returnValue = false
}
function mouseMove() {
    if (move) {
        dragObj.style.left = window.event.x - clickleft
        dragObj.style.top = window.event.y - clicktop
    }
}
function mouseUp() {
    move = 0
}
function bbimg(o){
  var zoom=parseInt(o.style.zoom, 10)||100;
  zoom+=event.wheelDelta/12;
  if (zoom>0) o.style.zoom=zoom+'%';
}
function featsize()
{
	var width1=images2.width;            
	var height1=images2.height;            
	var width2=760;            
	var height2=500;            
	var h=height1/height2;
	var w=width1/width2;
	if(height1<height2&&width1<width2)
	{
		images1.height=height1;            
		images1.width=width1;           
	}
	else
	{
		if(h>w)
		{
			images1.height=height2;          
			images1.width=width1*height2/height1;           
		}
		else
		{
			images1.width=width2;           
			images1.height=height1*width2/width1;          
		}
	}
	block1.style.left = 0;
	block1.style.top = 0;
}
</SCRIPT>
<title></title>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="init()"  ondragstart="return false" onselectstart ="return false" onselect="document.selection.empty()" oncopy="document.selection.empty()" onbeforecopy="return false"onmouseup="document.selection.empty()">
<noscript><iframe src=*></iframe></noscript>

<div align="center">
    <%
if rs("DesktopLx")=1 then
Response.Write"<div><object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0' width='550' height='400'><param name=movie value='"&rs("DesktopPic")&"'><param name=quality value=high><embed src='"&rs("DesktopPic")&"' quality=high pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash' width='550' height='400'></embed></object></div>"
elseif rs("DesktopLx")=0 then
Response.Write"<div id='hiddenPic'  style='position:absolute; left:433px; top:258px; width:77px; height:91px; z-index:1; visibility: hidden;'><img name='images2' src='"&rs("DesktopPic")&"' border='0'></div><div id='block1' onmouseout='drag=0' onmouseover='dragObj=block1; drag=1;' style='z-index:10; height: 60; left: 0; position: absolute; top: 0; width: 120'><img src='"&rs("DesktopPic")&"' name='images1' border='0' onmousewheel='return bbimg(this)' onload='featsize()'>"
end if
%>
  
</div>
</body>
</html>
<%
rs.close
set rs=nothing
%>
 
