Blogger 代码数据:post.url 用作带有图像按钮的可点击链接

问题描述 投票:0回答:2

我的网站是logjik.com。我的帖子中有两个社交按钮,它们也显示在我的主页中,我使用了这个解决方案,因为即使我在主页中,我也可以分享我的帖子链接(类似于 9gag 是我的主页):

.shr-btn-scl .twitterbtn{background-image:url(http://i.imgur.com/waBaJl0.png); display:block; background-repeat:no-repeat;
    height:42px;  
    width:185px;}
.shr-btn-scl .facebookbtn{background-image:url(http://i.imgur.com/XNIyP7z.png);display:block;
    height:42px;

    width:185px; background-repeat:no-repeat;
}

<div class='shr-btn-scl'>

<div class='btncontainer'>
<ul class='share-story'>                         
                            <li><a class='facebookbtn' data-title='Facebook' expr:href='&quot;http://www.facebook.com/sharer.php?u=&quot; + data:post.url + &quot;&amp;title=&quot;+ data:post.title' onclick='window.open(this.href, &apos;windowName&apos;, &apos;width=550, height=600, left=24, top=24, scrollbars, resizable&apos;); return false;' rel='nofollow'/>
                            </li>
                            <li>
                              <a class='twitterbtn' data-title='Twitter' expr:href='&quot;http://twitter.com/share?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' onclick='window.open(this.href, &apos;windowName&apos;, &apos;width=550, height=600, left=24, top=24, scrollbars, resizable&apos;); return false;' rel='nofollow'/>
  </li>                                                  
  </ul>
  </div>
    </div>

我想添加第三个按钮,其中包含一个可点击的图像,点击后将我从主页发送到帖子。有没有办法使用 data:post.url 作为可点击图像的链接?我怎样才能让这段代码工作:

`<a href="data:post.url" title=""><img border="0" src="http://i.imgur.com/ivHxNCj.jpg"/></a>`
javascript jquery html
2个回答
0
投票

我发现了一些东西可能对你有帮助。

我以为您正在谈论 Blogger 模板。如果是这样,这应该有效:

<a expr:href="data:post.url" title=""><img border="0" src="http://i.imgur.com/ivHxNCj.jpg"/></a>

0
投票

网站 asli Bambu99 hanya di link ini ya girls klik link alternatif BAMBU99 GACOR

© www.soinside.com 2019 - 2024. All rights reserved.