photo_show.asp

来自「利用C++编写的网络跟踪代码」· ASP 代码 · 共 438 行 · 第 1/2 页

ASP
438
字号
<!--#include file="Inc/syscode_Photo.asp"-->
<%
'请勿改动下面这三行代码
const ChannelID=4
Const ShowRunTime="Yes"
MaxPerPage=20
SkinID=0
PageTitle="查看图片"
dim UrlID
UrlID=trim(request("UrlID"))
if UrlID="" then
	UrlID=1
else
	UrlID=Clng(UrlID)
end if
FoundErr=False
if rs("PhotoLevel")<=999 then
	if UserLogined<>True then
		FoundErr=True
		ErrMsg=ErrMsg & "对不起,本图片为收费图片,要求至少是本站的注册用户才能欣赏!<br>您还没注册或者没有登录?所以不能欣赏本图片。请赶紧 <a href='User_Reg.asp'><font color=red><b>注册</b></font></a> 或 <a href='User_Login.asp'><font color=red><b>登录</a></font></a>吧!"
	else
		if UserLevel>rs("PhotoLevel") then
			FoundErr=True
			ErrMsg=ErrMsg & "对不起,本图片为收费图片,并且只有 <font color=blue>"
			if rs("PhotoLevel")=999 then
				ErrMsg=ErrMsg & "注册用户"
			elseif rs("PhotoLevel")=99 then
				ErrMsg=ErrMsg & "收费用户"
			elseif rs("PhotoLevel")=9 then
				ErrMsg=ErrMsg & "VIP用户"
			elseif rs("PhotoLevel")=5 then
				ErrMsg=ErrMsg & "管理员"
			end if
			ErrMsg=ErrMsg & "级别的用户</font> 才能欣赏。你目前的权限级别不够,所以不能欣赏。"
		else
			if ChargeType=1 and rs("PhotoPoint")>0 then
				if Request.Cookies("asp163")("Pay_Photo" & PhotoID)<>"yes" then
					if UserPoint<rs("PhotoPoint") then
						FoundErr=True
						ErrMsg=ErrMsg &"对不起,本图片为收费图片,并且欣赏本图片需要消耗 <b><font color=red>" & rs("PhotoPoint") & "</font></b> 点!"
						ErrMsg=ErrMsg &"而你目前只有 <b><font color=blue>" & UserPoint & "</font></b> 点可用。点数不足,无法欣赏本图片。请与我们联系进行充值。"
					else
						if lcase(trim(request("Pay")))="yes" then
							Conn_User.execute "update " & db_User_Table & " set " & db_User_UserPoint & "=" & db_User_UserPoint & "-" & rs("PhotoPoint") & " where " & db_User_Name & "='" & UserName & "'"
							response.Cookies("asp163")("Pay_Photo" & PhotoID)="yes"
						else
							FoundErr=True
							ErrMsg=ErrMsg & "<font color=red><b>注意</b></font>:欣赏本图片需要消耗 <font color=red><b>" & rs("PhotoPoint") & "</b></font>"
							ErrMsg=ErrMsg &"你目前尚有 <b><font color=blue>" & UserPoint & "</font></b> 点可用。阅读本文后,你将剩下 <b><font color=green>" & UserPoint-rs("PhotoPoint") & "</font></b> 点"
							ErrMsg=ErrMsg &"<br><br>你确实愿意花费 <b><font color=red>" & rs("PhotoPoint") & "</font></b> 点来欣赏本图片吗?"
							ErrMsg=ErrMsg &"<br><br><a href='Photo_Viewer.asp?Pay=yes&UrlID=" & UrlID & "&PhotoID=" & PhotoID & "'>我愿意</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href='index.asp'>我不愿意</a></p>"
						end if
					end if
				end if
			elseif ChargeType=2 then
				if ValidDays<=0 then
					FoundErr=True
					ErrMsg=ErrMsg & "<font color=red>对不起,本图片为收费图片,而您的有效期已经过期,所以无法欣赏本图片。请与我们联系进行充值。</font>"
				end if
			end if
		end if
	end if							
end if
if FoundErr<>True then
		rs("Hits")=rs("Hits")+1
		if datediff("D",rs("LastHitTime"),now())<=0 then
			rs("DayHits")=rs("DayHits")+1
		else
			rs("DayHits")=1
		end if
		if datediff("ww",rs("LastHitTime"),now())<=0 then
			rs("WeekHits")=rs("WeekHits")+1
		else
			rs("WeekHits")=1
		end if
		if datediff("m",rs("LastHitTime"),now())<=0 then
			rs("MonthHits")=rs("MonthHits")+1
		else
			rs("MonthHits")=1
		end if
		rs("LastHitTime")=now()
		rs.update
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%= dvhtmlencode(rs("PhotoName")) %></title>
<meta name="keywords" content="<%= dvhtmlencode(rs("PhotoName")) %>,美女图片,韩国网页模板,精美桌面"/>
<meta name="description" content="<%= dvhtmlencode(rs("PhotoName")) %>,明星写真,美女图片,自拍偷拍, 
韩国网页模板,QQ免费资源网致力于提供各种免费网络资源,QQ贴图,QQ呢称,QQ个性签名,QQ技巧,QQ空间代码,免费QQ资源等各种网络免费资源!]"/>
<STYLE type=text/css>BODY {
	SCROLLBAR-FACE-COLOR: #E4E4E4; SCROLLBAR-HIGHLIGHT-COLOR: #cccccc; SCROLLBAR-SHADOW-COLOR: #828282; SCROLLBAR-3DLIGHT-COLOR: #ffffff; SCROLLBAR-ARROW-COLOR: #797979; SCROLLBAR-TRACK-COLOR: #ECECEC; SCROLLBAR-DARKSHADOW-COLOR: #ffffff
}
</STYLE>
<script language=JavaScript>
function smallit(){            
	var height1=PhotoViewer.images1.height;            
	var width1=PhotoViewer.images1.width;            
	PhotoViewer.images1.height=height1/1.2;            
	PhotoViewer.images1.width=width1/1.2;           
}             
          
function bigit(){            
	var height1=PhotoViewer.images1.height;            
	var width1=PhotoViewer.images1.width;            
	PhotoViewer.images1.height=height1*1.2;          
	PhotoViewer.images1.width=width1*1.2;           
}             
function fullit()
{
	var width_s=screen.width-10;
	var height_s=screen.height-30;
	window.open("Photo_View.asp?UrlID=1&PhotoID=<%=PhotoID%>", "PhotoView", "width="+width_s+",height="+height_s+",left=0,top=0,location=no,toolbar=no,status=no,resizable=no,scrollbars=yes,menubar=no,directories=no");
}
function realsize()
{
	PhotoViewer.images1.height=PhotoViewer.images2.height;     
	PhotoViewer.images1.width=PhotoViewer.images2.width;
	PhotoViewer.block1.style.left = 0;
	PhotoViewer.block1.style.top = 0;
	
}
function featsize()
{
	var width1=PhotoViewer.images2.width;            
	var height1=PhotoViewer.images2.height;            
	var width2=760;            
	var height2=500;            
	var h=height1/height2;
	var w=width1/width2;
	if(height1<height2&&width1<width2)
	{
		PhotoViewer.images1.height=height1;            
		PhotoViewer.images1.width=width1;           
	}
	else
	{
		if(h>w)
		{
			PhotoViewer.images1.height=height2;          
			PhotoViewer.images1.width=width1*height2/height1;           
		}
		else
		{
			PhotoViewer.images1.width=width2;           
			PhotoViewer.images1.height=height1*width2/width1;          
		}
	}
	PhotoViewer.block1.style.left = 0;
	PhotoViewer.block1.style.top = 0;
}
</script>

<link href="img/css.CSS" rel="stylesheet" type="text/css">
</head>

<body bgcolor="#CCCCCC" topmargin="0" >
<table width="780" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
  <tr> 
    <td width="779"><table width="760" border="0" align="center"  cellpadding="0" cellspacing="0">
        <tr> 
          <td height="10"></td>
        </tr>
      </table>
      <table width="760" height="50" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr> 
          <td width="199" height="50" valign="bottom"><img src="new/logo.gif" width="199" height="41"></td>
          <td width="1" height="50" valign="middle"><table width="90%" height="50" border="0" align="right" cellpadding="0" cellspacing="0">
              <tr> 
                
              </tr>
            </table></td>
          <td width="560" valign="bottom"><table width="99%" height="23" border="0" align="right" cellpadding="0" cellspacing="0">
              <tr> 
                <td> <div align="right"> 
                    <%
	if ShowSiteChannel="Yes" then
		response.write strChannel
	else
		response.write "&nbsp;"
	end if
    	if ShowMyStyle="Yes" then
		response.write "<a href='#' onMouseOver='ShowMenu(menu_skin,100)'>自选风格&nbsp;</a>|"
	end if
	%>
                  </div></td>
              </tr>
            </table></td>
        </tr>
      </table>
      <table width="760" border="0" align="center"  cellpadding="0" cellspacing="0">
        <tr> 
          <td height="10"></td>
        </tr>
      </table>
      <table width="760" height="148" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr> 
          <td width="480" rowspan="2" align="center" valign="top" > <table width="100%" class="tde" border="0" cellspacing="0" cellpadding="0">
              <tr> 
                <td height="160"> <div align="center">
                    <table width="100%" border="0" align="center"  cellpadding="0" cellspacing="0">
                      <tr> 
                        <td height="2"></td>
                      </tr>
                    </table>
                    <% call ShowAD(1) %>
                  </div></td>
              </tr>
            </table></td>
          <td width="10" rowspan="2" valign="top">&nbsp; </td>
          <td width="270" height="161" valign="top" bgcolor="#F7F7F7"  class="tde"> 
            <table width="100%" border="0" align="center" cellpadding="1" cellspacing="0" bgcolor="#FFFFFF">
              <tr> 
                <td valign="top"> <table width="100%" height="29" border="0" cellpadding="0" cellspacing="0" bgcolor="#B6B6B6">
                    <tr> 
                      <td height="30" valign="top"> <table width="100%" height="26" border="0" cellpadding="0" cellspacing="0">
                          <tr> 
                            <td bgcolor="e1e1e1"><table width="100%" border="0" cellspacing="0" cellpadding="0">

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?