侧边栏推广小工具-子比主题论坛-WordPress-轻论坛

侧边栏推广小工具

前言

这是一款简洁实用的小工具区块,适合用在WordPress小工具中,可以方便的放一张商品介绍图片和简洁的特色介绍,还有一个大气实用的跳转按钮,很适合在一些需要展示指定内容的场合使用。

效果截图

c14b5b64db113831

教程

1.进入后台,找到  外观—自定义

QM7W[%1RUDLWS7JSE(W[4OK.png

2.点击小工具

$[HBN}}($[2CP164(VND@DL.png

3.点击 {论坛}首页-侧边栏

QQ图片20220315220708.png

4.点击添加小工具  下滑找到 自定义html

R{E_RPUWWRS5TN}1[L`W4KG.png

5.点击展开刚添加的小工具,将代码填入

QQ图片20220315220835.png

6.或者根据自己的需求放到需要的位置也可以。

html代码

<div class="textwidget custom-html-widget"><div class="widget" style="top: 0px; visibility: visible; animation-name: fadeInUp;padding: 0px;">
  <div class="widget_product">
               
   <img title="zibll子比主题" src="https://www.atbkw.cn/wp-content/uploads/aotian/qita/bedfaf010493-2.webp"> 
   <div class="product_content"> 
    <div class="product_info">
                   
     <h2>Zibll-子比主题-本站同款</h2> 
     <ul>
    <li><i class="fa fa-check"></i> 搭建网站从一个优秀的主题开始!</li>
    <li><i class="fa fa-check"></i> 一次购买包永久免费更新</li> 
    <li><i class="fa fa-check"></i> 强大的模板群为你解决主题问题</li> 
    <li><i class="fa fa-check"></i> 通过下方链接购买 <span class="but c-yellow">立减10</span>   元!</li>
     </ul> 
    </div> 
    <div class="price_sale">
     <strong><small>¥</small>399</strong>
     <h2>官方统一售价</h2>
    </div>                
    <a class="btn" href="https://www.zibll.com?ref=982" target="_blank" rel="noopener">立即购买 - zibll</a> 
   </div> 
  </div>
   </div></div>

把下面代码复制到主题后台–>自定义代码–>自定义CSS样式-中保存即可

css代码

.widget {
    clear: both;
    position: relative;
    margin-bottom: 20px;
    overflow: hidden;

}
.widget_product {
    background: #fff;
    background-color:transparent;/*透明色*/
}
.product_content {
    padding: 15px;

}
.product_info h2 {
    font-size: 20px;

    margin: 0;
    font-weight: bold;
    padding: 5px 0 10px 0;

}
.widget ul {
    zoom: 1;
    list-style: none;
    padding: 0;
    margin: 0;
}
.product_info>ul>li {
    font-size: 13px;
    margin-bottom: 28px;
    list-style: none;
}
.price_sale {
    border-top: 1px solid #eee;
    padding: 10px 0px;
}
.price_sale strong {
    float: right;
    font-size: 20px;
    line-height: 1;
    font-weight: 100;
}
small, .small {
    font-size: 85%;
}
.price_sale h2 {
    margin: 0;
    font-size: 14px;
    color: #999;
    line-height: 20px;
}
.product_content>.btn {
  top: 5px;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    width: 100%;
  background: linear-gradient(-125deg,#54e38e 0%, #41c7Af 100%);
  box-shadow: 0 3px 10px -1px #41c7Af!important;
    color: #ffffff;

}

/*侧边栏主题推荐*/
请登录后发表评论

    没有回复内容


Warning: error_log(/www/wwwroot/www.qingluntan.cn/wp-content/plugins/spider-analyser/#log/log-2516.txt): failed to open stream: No such file or directory in /www/wwwroot/www.qingluntan.cn/wp-content/plugins/spider-analyser/spider.class.php on line 2900