亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

z-blog評(píng)論留言的引用按鈕寫(xiě)法詳解

互聯(lián)網(wǎng)   發(fā)布時(shí)間:2009-06-06 15:43:16   作者:jb51   我要評(píng)論
關(guān)鍵字描述:詳解 按鈕 引用 評(píng)論 留言 < " > class .innerHTML z-blog默認(rèn)主題的模板b_article_comment.html中 <ul class="msg"> <li class="msgname"><span class="comment-quote-icon"><
關(guān)鍵字描述:詳解 按鈕 引用 評(píng)論 留言 < " > class .innerHTML

z-blog默認(rèn)主題的模板b_article_comment.html中

<ul class="msg">

    <li class="msgname"><span class="comment-quote-icon"><a onclick="InsertQuote(this.parentNode.parentNode.parentNode.getElementsByTagName('a')[2].innerHTML,this.parentNode.parentNode.parentNode.getElementsByTagName('li')[2].innerHTML);return false;" href=""><img src="<#ZC_BLOG_HOST#>image/common/quote.gif" height="9" width="9" alt="quote" title="quote" /></a></span>&nbsp;<a name="cmt<#article/comment/id#>"><#article/comment/count#></a>.<a><#article/comment/name#></a></li>

    <li class="msgurl"><a href="<#article/comment/urlencoder#>" rel="nofollow" target="_blank"><#article/comment/url#></a></li>

    <li class="msgarticle"><#article/comment/content#></li>

    <li class="msgtime"><#article/comment/posttime#>&nbsp;<a href="#comment" onclick="RevertComment('<#article/comment/id#>')"><#ZC_MSG265#></a></li>

</ul>

要把其格式改成如下結(jié)構(gòu),z-blog引用評(píng)論的按鈕要如何寫(xiě)呢?:

<div class="msg">

<cite>評(píng)論者</cite>

<blockquote>評(píng)論內(nèi)容</blockquote>

<p>網(wǎng)站</p>

<p>時(shí)間</p>

</div>
  • 講解z-blog引用所用的JS函數(shù):
    1. 引用的函數(shù): InsertQuote(參數(shù)1[評(píng)論者],參數(shù)2[評(píng)論內(nèi)容])
    2. this.parentNode 表示該節(jié)點(diǎn)的上一節(jié)點(diǎn)
    3. getElementsByTagName('a')[2].innerHTML 表示獲取第二個(gè)<a>元素的內(nèi)容,即<#article/comment/name#>
    4. 同上,getElementsByTagName('li')[2].innerHTML 為<#article/comment/content#>

    修改后的代碼

    <div class="msg">
    
    <a onclick="InsertQuote(this.parentNode.getElementsByTagName('CITE')[0].innerHTML,this.parentNode.getElementsByTagName('BLOCKQUOTE')[0].innerHTML);return false;" href="#comment">引用</a>
    
    <cite>評(píng)論者</cite>
    
    <blockquote>評(píng)論內(nèi)容</blockquote>
    
    <p>網(wǎng)站</p>
    
    <p>時(shí)間</p>
    
    </div>

    相關(guān)文章

    最新評(píng)論