⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 默认图片内容页模板(样式一).html

📁 Enterprise Template for BizIdea 2.0, with full pictures and aspx files.
💻 HTML
字号:
{PE.DataSource id="cone" datasource="图片_内容页" itemId="@RequestInt_id" xslt="true" /}
<!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" lang="UTF-8">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta content="{PE.Field id="cone" fieldname="Title" /}" name="Description" />
<meta content="{PE.Field id="cone" fieldname="Keyword" /}" name="Keywords" />
<title>{PE.Field id="cone" fieldname="Title" /}-{PE.SiteConfig.sitename /}</title>
<link href="{PE.SiteConfig.ApplicationPath/}Skin/mall/default.css" rel="stylesheet" type="text/css" />
<link href="{PE.SiteConfig.ApplicationPath/}Skin/mall/common.css" rel="stylesheet" type="text/css" />
<link href="{PE.SiteConfig.ApplicationPath/}Skin/mall/photo.css" rel="stylesheet" type="text/css" />
<link href="{PE.SiteConfig.ApplicationPath/}Skin/mall/commentary.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="{PE.SiteConfig.ApplicationPath/}Skin/mall/js/tab.js"></script>
<script language="javascript" type="text/javascript" src="{PE.SiteConfig.ApplicationPath/}JS/Common.js"></script>
<script language="javascript" type="text/javascript" src="{PE.SiteConfig.ApplicationPath/}JS/jsPopup.js"></script></head>
<body onload="commentinit()">
{PE.Label id="商城网站顶部(内容)" /}
<div id="center_all" class="main" class="main">
  <div id="main_bg">
    <div id="main_right">
      <div id="main_right_box">
        <!-- 网站位置导航信息开始 -->
        <div class="navigation">
          您现在的位置:<a href="{PE.SiteConfig.sitepath/}">{PE.SiteConfig.sitename /}</a>>>{PE.Label id="当前位置导航" nodeId="{PE.Field id="cone" fieldname="NodeID" /}" orientationNodeID="{PE.Field id="cone" fieldname="NodeID" /}" linkOpenType="2" postfix="正文内容" /} </div>
        <!-- 网站位置导航信息结束 -->
        <div class="spacing"></div>
        {PE.Label id="右侧广告一" /}
        <div class="c_spacing"> </div>
			<!-- 测试内容开始 -->
			
			<div class="c_spacing">
			</div>
			<div class="c_main_box">
				<div class="p_content_text">
					<div class="c_content_overflow">
				    {PE.Charge}
					{PE.Label id="显示图片" itemId="@RequestInt_id" charge="true"  showerr="true" /}
				    {/PE.Charge}
					</div>
				</div>
				<div class="c_bot_text">
					图片名称:{PE.Field id="cone" fieldname="Title" /} | 作者:<a href="{PE.SiteConfig.ApplicationPath/}Common/ShowAuthor.aspx?authorname={PE.Field id="cone" fieldname="LinkAuthor" /}">{PE.Field id="cone" fieldname="Author" /}</a> | 来源:<a href="{PE.SiteConfig.ApplicationPath/}Common/ShowCopyFrom.aspx?copyfrom={PE.Field id="cone" fieldname="LinkCopyFrom" /}">{PE.Field id="cone" fieldname="CopyFrom" /}</a> | 发布时间:{PE.Field id="cone" fieldname="UpdateTime" /}<span>【<a href="{PE.SiteConfig.applicationpath/}ShowComment.aspx?id={PE.Field id="cone" fieldname="GeneralID" /}">查看评论</a>】</span>
				</div>
			</div>
			<div class="c_spacing">
			</div>
			
			<!-- 测试内容结束 -->

			<div class="c_spacing">
			</div>
			<div class="p_info">
			<h4>图片简介:</h4>
			{PE.Field id="cone" fieldname="PhotoIntro" /}
			</div>
        <!-- 评论开始 -->
   <span id="commentform"></span>
        <!-- 评论结束 -->
         </div>
    </div>
    {PE.Label id="图片节点左侧" /} </div>
</div>
{PE.Label id="商城网站底部" /}

<!-- 评论变量区 -->
<input id="username" type="hidden" value="游客" />
<input id="position" type="hidden" value="1" />
<input id="private" type="hidden" value="0" />
<input id="score" type="hidden" value="3" />
<input id="face" type="hidden" value="Images\Comment\01.gif" />
<input id="gid" type="hidden" value="@RequestInt_id" />
<input id="nid" type="hidden" value="{PE.Field id="cone" fieldname="NodeID" /}" />
<input id="tid" type="hidden" value="1" />
<!-- 评论变量区 -->
<script language="javascript" type="text/javascript">
function redirecturl(url, tarid)
{
    location=url.replace(/{\$pageid\/}/g,tarid);
}

//评论相关代码
function commentinit()
{
    var x = new AjaxRequest('XML','commentform');
    x.labelname = "内容评论PK标签";
    x.para = ['itemId=@RequestInt_id'];
    x.currentpage = 1;
    x.post('updatelabel', '{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
        var xml = x.createXmlDom(s);
        document.getElementById("commentform").innerHTML = xml.getElementsByTagName("body")[0].firstChild.data;
        changepage(1,'评论列表','JS_基本风格');
        getcurrentuserinfo()
    });
}

function SetPosition(st)
{
     for (i=-1;i<2;i++){
          if(i == st){
              document.getElementById("Positon" + i).className="PK_mouseover";
          }
          else{
              document.getElementById("Positon" + i).className="PK_title";
          }
     }
     document.getElementById("position").value = st;
}

function addcomment()
{
    if(!document.getElementById("guest").checked)
    {
        var strEmail = document.getElementById("email").value;
	    var regEmail = /^([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/;
    	var matchArray = strEmail.match(regEmail);
    	if(matchArray == null)
	    {
            alert("请输入正确的Email格式!");
            document.getElementById("email").focus();
            return false; 
	    }
	    
        if(document.getElementById("iusername").value == '')
        {
            alert("请输入用户名");
            document.getElementById("iusername").focus();
            return false;           
        }
        else
        {
            document.getElementById("username").value = document.getElementById("iusername").value;
        }
    }
//    if(document.getElementById("commenttitle").value == '')
//    {
//        alert("请输入标题");
//        document.getElementById("commenttitle").focus();
//        return false; 
//    }
    if(document.getElementById("content").value == '')
    {
        alert("请输入评论内容");
        document.getElementById("content").focus();
        return false;                
    }
    var x = new AjaxRequest('XML','status');
    x.para = ['username', 'commenttitle', 'content', 'email', 'face', 'gid', 'nid', 'tid', 'private', 'position', 'score'];
    x.paratype = ['nohtml','nohtml','nohtml']
    x.post('addcomment', '{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
        var xml = x.createXmlDom(s);
        var  status = xml.getElementsByTagName("status")[0].firstChild.data;
        document.getElementById("status").style.display = "none";
        switch (status)
        {
            case "ok":
                changepage(1,'评论列表','JS_基本风格');
                break;
            case "check":
                alert("发表评论成功,请等待管理员审核。");  
                break;
            case "err":
                alert("发表评论失败!");  
                break;
            case "nopurview":
                alert("此栏目已禁止发表评论!");  
                break;
            case "noTourists":
                alert("此栏目已禁止游客发表评论!");  
                break;                    
            default:
                alert("发表评论失败!"); 
                break;
        }
        document.getElementById("content").value = '';
    });
}

function addpkzone(commentid,position,content)
{
    var x = new AjaxRequest('XML','status');
    x.para = ['commentid='+ commentid, 'position=' + position, 'content=' + content];
    x.post('addpkzone', '{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
        var xml = x.createXmlDom(s);
        var  status = xml.getElementsByTagName("status")[0].firstChild.data;
        document.getElementById("status").style.display = "none";
        switch (status)
        {
            case "ok":
                changepage(1,'评论列表','JS_基本风格');
                break;                  
            default:
                alert("辩论失败!"); 
                break;
        }
    });
}

function changepage(pagenum,sourcename,spanname)
{
    var x = new AjaxRequest('XML','pe100_' + sourcename);
    x.labelname = sourcename;
    x.currentpage = pagenum; 
	x.para = ['itemId=@RequestInt_id', 'outputQty=10', 'page=true', 'pagesize=10','currentPage='+pagenum];
	x.post('updatelabel', '{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
        var xml = x.createXmlDom(s);
        var plstr = "";
        for (var i=0; i<xml.getElementsByTagName("body")[0].childNodes.length; i++)     
        {
            plstr += xml.getElementsByTagName("body")[0].childNodes[i].nodeValue;
        }
        document.getElementById("pe100_" + sourcename).innerHTML = plstr;
        updatepage(spanname, sourcename, xml);
    });
}

function updatepage(spanname, sourcename, xml)
{
    if(parseInt(xml.getElementsByTagName("total")[0].firstChild.data) > 0)
    {
        var x = new AjaxRequest('XML','pe100_page_' + sourcename);
        x.labelname = spanname;
        x.sourcename = sourcename;
        x.total = xml.getElementsByTagName("total")[0].firstChild.data;
        x.currentpage = xml.getElementsByTagName("currentpage")[0].firstChild.data;
        x.pagesize = xml.getElementsByTagName("pagesize")[0].firstChild.data;
	    x.post('updatepage', '{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
            var xml = x.createXmlDom(s);
            if(document.getElementById("pe100_page_" + sourcename) != null)
            {
                var plstr = "";
                for (var i=0; i<xml.getElementsByTagName("body")[0].childNodes.length; i++)     
                {
                    plstr += xml.getElementsByTagName("body")[0].childNodes[i].nodeValue;
                }
                document.getElementById("pe100_page_" + sourcename).innerHTML = plstr;
            }
	});
    }
}

function setprivate()
{
    if(document.getElementById("open").checked)
    {
        document.getElementById("private").value = 0;
    }
    else
    {
        document.getElementById("private").value = 1;
    }
}
 
function getcurrentuserinfo()
{ 
    try{
        var x = new AjaxRequest('XML','');
	x.post('logincheck','{PE.SiteConfig.ajaxsitepath/}ajax.aspx', function(s) {
            var xml = x.createXmlDom(s);
            if(xml.getElementsByTagName("status")[0].firstChild.data == "ok")
            {
                if(document.getElementById("iusername")!=null)
                {
                    document.getElementById("iusername").value = xml.getElementsByTagName("username")[0].firstChild.data;
                    document.getElementById("email").value = xml.getElementsByTagName("email")[0].firstChild.data;
                    document.getElementById("iusername").disabled = true;
                    document.getElementById("email").disabled = true;
                }
            }
        });
      }
      catch(e){
      };
}

function setguest()
{
    if(document.getElementById("guest").checked)
    {
        document.getElementById("spanusername").style.display = 'none';
        document.getElementById("spanemail").style.display = 'none';
    }
    else
    {
        document.getElementById("spanusername").style.display = '';
        document.getElementById("spanemail").style.display = '';
    }
}

function ChangeStar(index, isfixed){
     var colStars = document.getElementById("divStars").getElementsByTagName("input");
     var i = 0;
     var k = isfixed? parseInt(document.getElementById("score").value) : index;

     for(i=0; i<colStars.length; i++){
             colStars[i].src = (i<k? "{PE.SiteConfig.applicationpath/}Images/fstar.gif" : "{PE.SiteConfig.applicationpath/}Images/estar.gif");
     }
}

function StarClick(index)
{
    document.getElementById("score").value=index;
}

function StarMouseOver(index){
    ChangeStar(index,false);
}

function StarMouseOut(){
    ChangeStar(0,true);
}
</script>
</body>
</html>

⌨️ 快捷键说明

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