<%@ page language="C#" autoeventwireup="true" inherits="plugin_gallery1_index, ZKCMS" enableviewstatemac="false" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register TagName="meta" TagPrefix="UC" Src="~/s/include/meta.ascx" %>
<%@ Register TagName="head" TagPrefix="UC" Src="~/s/include/head.ascx" %>
<%@ Register TagName="tip_bar" TagPrefix="UC" Src="~/s/include/tip_bar.ascx" %>
<%@ Register TagName="foot" TagPrefix="UC" Src="~/s/include/foot.ascx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
    <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
    <title><asp:Literal ID="Literal_PageTitle" runat="server"></asp:Literal>_<%=ZK.config("sitetitle") %></title>
    <meta name="keywords" content="<%=ZK.config("sitekeywords") %>" />
    <meta name="description" content="<%=ZK.config("sitedescription") %>" />
    <UC:meta ID="meta1" runat="server" />
    <style type="text/css">
        #GalleryBox
        {
            width: 939px;
            margin:0 auto;  
            background-image: url(/plugin/gallery1/bg.gif);         
        }
        #GalleryBox #GalleryImage
        {
            position: relative;
            width: 925px;
            height: 500px;
            overflow:hidden;
            padding: 5px;
            border: 2px solid #4a4a4a;
            background: url(/s/skin/loading.gif) center center no-repeat;            
            
        }
        #GalleryBox .GalleryImageMask
        {
        	position:absolute;
        	background-image: url(/plugin/gallery1/bg.gif);        
        	width:925px;
        	height:5px;
        	overflow:hidden;        	
        	bottom:0;
        	z-index:999;
        }
        #GalleryBox #GalleryImage img
        {            
            display:block;
        	margin:0 auto;
        }
        #GalleryBox .GalleryNav
        {
            position: absolute;            
            width: 50%;
            z-index: 100;
            cursor: pointer;
        }
        #GalleryBox #Gallery_previmg
        {
            left: 0;
            background: url(/plugin/gallery1/left.png) left center no-repeat;
            height: 500px;
            _background: url(/plugin/gallery1/left.gif) left center no-repeat;
        }
        #GalleryBox #Gallery_nextimg
        {
            right: 0;
            background: url(/plugin/gallery1/right.png) right center no-repeat;
            height: 500px;
            _background: url(/plugin/gallery1/right.gif) right center no-repeat;
        }
        #GalleryBox #GalleryThumbWrap
        {            
            width: 925px;
            height: 100px;
            padding: 5px;
            border: 2px solid #4a4a4a;    
            border-top-width:0;     
            border-bottom-width:0;  
        }
        #GalleryBox #GalleryThumbArea
        {
            position: relative;
            overflow: hidden;
            width: 925px;
            height: 100px;
        }
        #GalleryBox #GalleryThumbs
        {
            position: absolute;
            width: 5000px;
            height: 100px;
        }
        #GalleryBox #GalleryThumbs li
        {
            float: left;
            margin-right: 5px;            
            width:140px;
            overflow:hidden;
            padding: 2px;
            border: solid 3px #666;
            background-color:#fff;
            text-align:center;
        }
        #GalleryBox #GalleryThumbs li img
        {           
            filter: Alpha(Opacity=100);
            -moz-opacity: 1;
            opacity: 1; 
            cursor: pointer;
            display:block;
            margin-left:auto;
            margin-right:auto;          
        }
        #GalleryBox #GalleryThumbs .on
        {
        	
        }
        #GalleryBox #GalleryThumbs .on img
        {
            border-color: #595959;
            filter: Alpha(Opacity=40);
            -moz-opacity: 0.4;
            opacity: 0.4;
        }
        #GalleryBox .GalleryThumbTurn
        {
        	position:absolute;
        	width:20px;
        	height:100px;        	
        	z-index:200;
        	cursor:pointer;
        	filter: Alpha(Opacity=60);
            -moz-opacity: 0.6;
            opacity: 0.6;
        }
         #GalleryBox #GalleryThumbTurnLeft
        {
        	background: url(/plugin/gallery1/GalleryThumbTurn.png) 0 0 no-repeat;
        }
         #GalleryBox #GalleryThumbTurnRight
        {
        	margin-left:905px;
        	background: url(/plugin/gallery1/GalleryThumbTurn.png) -20px 0 no-repeat;
        	
        }
        #GalleryBox #GalleryImage.GalleryImage_ClassName
        {
        	background: url(/plugin/gallery1/nopic.gif) center center no-repeat;
        }
        .self_view_content
        {
        	color:#fff;
        	font-size:14px;
        	line-height:2;
        	padding:3px 5px 8px 12px;
        }
    </style>
</head>
<body>
    <div class="wrap">
        <a name="pagetop" id="pagetop"></a>
        <UC:head ID="head1" runat="server" />
        <UC:tip_bar ID="tip_bar1" runat="server" />

        <div class="box">
            <div class="c1 mt5">
                <div class="b">
                    <div class="fl">
                    </div>
                    <div class="con" style="width:800px">
                        <asp:Literal ID="Literal_Title" runat="server"></asp:Literal></div>
                    <div class="fr">
                    <script type="text/javascript">
                    function self_AP(){
                    if(auto==false){auto=true;document.getElementById("self_AP_text").innerHTML="暂停播放";}else{auto=false;clearTimeout(ia.timer);document.getElementById("self_AP_text").innerHTML="自动播放";}
                    slideShow();
                    }
                    </script>
                    <a href="#self_anchor1" id="self_AP_text" onclick="self_AP()">自动播放</a>
                    </div>
                    <div class="clear">
                    </div><a name="self_anchor1" id="self_anchor1"></a>
                </div>
                <div class="v">
<div style="padding:4px 0"><div id="GalleryBox"><div id="GalleryImage"><div class="GalleryImageMask"></div><a href="javascript:imgNav(-1)" class="GalleryNav" id="Gallery_previmg" onfocus="this.blur()"></a><a href="javascript:imgNav(1)" class="GalleryNav" id="Gallery_nextimg" onfocus="this.blur()"></a></div><div id="GalleryThumbWrap"><div class="GalleryThumbTurn" id="GalleryThumbTurnLeft" onclick="scrlThumbs(-1);" onmouseover="hover(this,1)" onmouseout="hover(this,0.6)"></div><div class="GalleryThumbTurn" id="GalleryThumbTurnRight" onclick="scrlThumbs(1);" onmouseover="hover(this,1)" onmouseout="hover(this,0.6)"></div><div id="GalleryThumbArea">
                <ul id="GalleryThumbs">
                    <asp:Literal ID="Literal1" runat="server"></asp:Literal>                    
                </ul>
            </div>
        </div>
        <div class="none" id="self_view_content"></div>
    </div>

    <script type="text/javascript">var imgid='GalleryImage';var imgdir='/plugin/gallery1/big/';var imgext='.jpg';var thumbid='GalleryThumbs';var auto=false;var autodelay=3;</script>

    <script type="text/javascript" src="/plugin/gallery1/GallerySlide.js"></script>

    <script type="text/javascript">
ss=150;fs=25;document.onmousemove = null;
var GalleryCurrentThumbPage=0;var GalleryThumbAreaWidth=930;var GalleryThumbPageSize=6;var GalleryMaxThumbPage=<asp:Literal ID="MaxPage" runat="server"></asp:Literal>;var GalleryCurrentID=1;var GalleryBtnImgNav=true;
function scrlThumbs(d){
clearInterval(ta.timer); 
if(d == -1){GalleryCurrentThumbPage--; if(GalleryCurrentThumbPage<0)GalleryCurrentThumbPage=0;}else{GalleryCurrentThumbPage++;if(GalleryCurrentThumbPage>GalleryMaxThumbPage)GalleryCurrentThumbPage=GalleryMaxThumbPage;}
ta.timer = setInterval(function(){scrlMv(d,GalleryCurrentThumbPage*GalleryThumbAreaWidth)},st);
}
function ResetGalleryBtnImgNav(){GalleryBtnImgNav=true;document.getElementById("GalleryImage").style.backgroundImage="url(/s/skin/loading.gif)";}
slideShow();
function GallerySetInterval(){
var arr1=document.getElementById("GalleryThumbs").getElementsByTagName("li");if(arr1.length==0){document.getElementById("Gallery_previmg").style.display="none";document.getElementById("Gallery_nextimg").style.display="none";document.getElementById("GalleryImage").className="GalleryImage_ClassName";return;}
for(var i=0;i<arr1.length;i++)arr1[i].className="";arr1[GalleryCurrentID-1].className="on";
var imgsrc=arr1[GalleryCurrentID-1].childNodes[0].src;
if(imgsrc.indexOf("?psize=")!=-1){
var width=imgsrc.substring(imgsrc.indexOf("?psize=")+7);var height=width.substring(width.indexOf(",")+1);width=width.substring(0,width.indexOf(","));
if(width>925){document.getElementById(GalleryCurrentID).style.width="925px";height=(925/width)*height;}
document.getElementById("GalleryImage").style.height=height+"px";document.getElementById("Gallery_previmg").style.height=height+"px";document.getElementById("Gallery_nextimg").style.height=height+"px";
}
}
setInterval(GallerySetInterval,10); 
function GalleryUpdateCurrentThumbPage(){
var c=Math.ceil(GalleryCurrentID/GalleryThumbPageSize);c=c-1;
var d=-1;if(c>=GalleryCurrentThumbPage)d=1;GalleryCurrentThumbPage=c;
ta.timer = setInterval(function(){scrlMv(d,c*GalleryThumbAreaWidth)},st);
}
function set_self_view_content(){
ajax("post","/plugin/gallery1/index.aspx?act=ajax&type=<%=WM.RQ("type") %>&id=<%=WMencrypt.Base64Decode_Url(WM.RQ("par4")) %>&cid="+GalleryCurrentID,"",function OnHandler(){if(xmlHttp.readyState == 4){if(xmlHttp.responseText!=''){document.getElementById('self_view_content').innerHTML=xmlHttp.responseText;document.getElementById('self_view_content').className='self_view_content';}else{document.getElementById('self_view_content').innerHTML='';document.getElementById('self_view_content').className='none';}}});
}
setInterval(set_self_view_content,1000); 
document.onkeydown = function chang_page(e){var theEvent=window.event||e;var keyNum=theEvent.keyCode||theEvent.which;if (keyNum== 37)imgNav(-1);else if (keyNum== 39)imgNav(1);}
//
function _GalleryThumbsOnClick(){
function _GalleryThumbsOnClick_(){document.getElementById("GalleryImage").style.backgroundImage="url(/s/skin/loading.gif)";}
document.getElementById("GalleryImage").style.backgroundImage="none";setTimeout(_GalleryThumbsOnClick_,500);
}
    </script>
                        
                        
                    </div>
                </div>
            </div>
        </div>
 
        <UC:foot ID="foot1" runat="server" />
    </div>
</body>
</html>
<asp:Panel ID="Panel2" runat="server" Visible="false">
    <div style="height:1px; overflow:hidden;">   
        <embed src="/s/skin/dewplayer.swf" width="60" height="20" type="application/x-shockwave-flash" quality="high" wmode="transparent" flashvars="son=<asp:Literal ID="LiteralMP3" runat="server"></asp:Literal>&autoplay=1&autoreplay=1&showtime=1&volume=100">
    </div>
</asp:Panel> 