Home » » Kode Featured Post SEO Friendly untuk Blogger

Kode Featured Post SEO Friendly untuk Blogger

Kode Featured Post SEO Friendly untuk Blogger
Kode Featured Post SEO Friendly untuk Blogger

PASANG Featured Post bawaan blogger dengan cara Layout > Add a Gadget > Featured Post. Pilih posting yang akan ditampilkan.

Setelah itu, pindahkan atau geser widgetnya ke atas widget Blog Posts agar tampil di bawah navigasi menu.

Untuk menampilkan Featured Posts seperti gambar di atas, masuk ke template dan ganti kode widget featured post dengan kode ini:

          <b:widget id='FeaturedPost1' locked='true' title='Featured Post' type='FeaturedPost' version='1' visible='true'>
            <b:includable id='main'>
<b:if cond='data:blog.url == data:blog.homepageUrl'>
  <!-- Only display title if it's non-empty -->
  <b:if cond='data:title != &quot;&quot;'>
    <h2 style='display:none'><data:title/></h2>
  </b:if>
  <b:include name='content'/>
</b:if>
</b:includable>
            <b:includable id='content'>
  <div class='post-summary'>
    <b:if cond='data:showFirstImage and data:postFirstImage != &quot;&quot;'>
      <img alt='featured image seo' class='image' expr:src='data:postFirstImage'/>
    </b:if>
    <strong style='color:#F55B77;font-weight:700;'>Featured Post</strong>
    <b:if cond='data:showPostTitle and data:postTitle != &quot;&quot;'>
      <h3><a expr:href='data:postUrl'><div style='font-size:18px;padding-right:10px;font-weight:700;line-height:normal;'>
  <data:postTitle/></div></a></h3>
    </b:if>
    <p style='font-size:13px;line-height:19px;margin-bottom:20px'>
      <data:postSummary/>
    </p>
  </div>
  <style type='text/css'>
    .image {width:47%;height:160px;margin:0 15px 5px 0;position:relative;float:left;}
    .post-summary {width: 100%;
    min-height: 170px;
    padding: 0px;
    margin: 10px 10px 10px 0;
    height: auto;
    border-bottom: 1px solid #ddd;}
@media screen and (max-width:680px){
.image {width: 100%;}
    }
  </style>
</b:includable>
          </b:widget>
Share this article :

0 comments:

Post a Comment

 
Copyright © 2017 Johny Wuss Responsif - All Rights Reserved
Template by Creating Website and CB Blogger