RiPro 主题幻灯片美化教程

RiPro 主题幻灯片美化教程

RiPro 主题幻灯片美化教程

1. ripro – > parts -> home-mode -> slider.php 文件,找到如下代码

<div class="section pt-0 pb-0">
    <div class="module slider big diy owl <?php echo esc_attr( $mode_slider['autoplay'] ? ' autoplay' : '' ); ?>">
    <?php foreach ($mode_slider['diy_data'] as $key => $item) {
        echo '<article class="post lazyload visible" data-bg="'.esc_url( $item['_img'] ).'">';
          echo '<div class="container">';
          echo '<h2 class="slider-title">'.$item['_title'].'</h2>';
          echo '<h3 class="slider-desc">'.$item['_desc'].'</h3>';
          echo '<a'.( $item['_blank'] ? ' target="_blank"' : '' ).' class="u-permalink" href="'.esc_url( $item['_href'] ).'"></a>';
          echo '</div>';
        echo '</article>';
    }?>
    </div>
</div>

2. 将如上代码替换为

<div class="section">
 	<div class="container">
    	<div class="module slider big owl nav-white <?php echo esc_attr( $mode_slider['autoplay'] ? ' autoplay' : '' ); ?>">
		<?php foreach ($mode_slider['diy_data'] as $key => $item) {?>
        	<article class="post lazyload visible" data-bg="<?php echo esc_url( $item['_img'] );?>">
				<div class="container">
					<a target="_blank" class="u-permalink" rel="noopener noreferrer">"></a>
				</div>
        	</article>
		<?php } ?>
    	</div>
	</div>
</div>

3. ripro -> assets -> css-> diy.css 添加如下样式

.section {padding-top: 20px;}

搜索框美化教程:

1. ripro – > parts -> home-mode -> search.php 文件,找到如下代码

<div class="section pt-0 pb-0">
	<div class="row">
		<div class="home-filter--content lazyload" data-bg="<?php echo esc_url( @$home_search_mod['bgimg'] ); ?>">
			<div class="container">
				<h3 class="focusbox-title"><?php echo $title = ($home_search_mod['title']) ? $home_search_mod['title'] : '搜索本站精品资源' ;?></h3>
				<p class="focusbox-desc"><?php echo $desc = ($home_search_mod['desc']) ? $home_search_mod['desc'] : '本站所有资源均为高质量资源,各种姿势下载。' ;?></p>
			    <form class="mb-0" method="get" autocomplete="off" action="<?php echo home_url(); ?>">
			        <div class="form-box search-properties">
			            <div class="row">
			                <div class="col-xs-12 col-sm-6 col-md-9">
			                    <div class="form-group mb-0">
			                        <input type="text" class="home_search_input" name="s" placeholder="<?php echo $mode_search['tips'];?>">
			                    </div>
			                </div>
			                <div class="col-xs-12 col-sm-6 col-md-3">
			                    <input type="submit" value="搜索"  class="btn btn--block">
			                </div>
			            </div>
			            <div class="home-search-results"></div>
			        </div>
			    </form>
			</div>
		</div>
	</div>
</div>

2. 将如上代码替换为

<div class="section bgcolor-fff search_section">
	<div class="container">
		<div class="row">
			<div class="home-filter--content">
				<form class="mb-0" method="get" autocomplete="off" action="<?php echo home_url(); ?>">
					<div class="form-box search-properties mb-0">
					    <div class="row">
					        <div class="col-xs-12 col-sm-6 col-md-9">
					            <div class="form-group mb-0">
					                <input type="text" class="home_search_input" name="s" placeholder="请输入关键词搜索。。。">
					                </div>
					            </div>
					        <div class="col-xs-12 col-sm-6 col-md-3">
					            <input type="submit" value="搜索"  class="button transparent home_search">
					        </div>
					    </div>
					    <div class="home-search-results"></div>
					</div>
				</form>
			</div>
		</div>
	</div>
</div>
.row,.navbar .menu-item-mega>.sub-menu{margin-left:-10px;margin-right:-10px;}
.home-filter--content:before{background-color:rgba(91,91,91,0);}
.home-filter--content {background: linear-gradient(to right, #f6f6f6, #f6f6f6, #f6f6f6);}
.ripro-dark .home-filter--content {background: linear-gradient(to right, #232425, #232425, #232425);}
.home-filter--content .form-box{margin-right:10%;margin-left:10%;}
.button,input[type="submit"],button[type="submit"],.navigation .nav-previous a,.navigation .nav-next a{width:100%;}
分享到 :
相关推荐

发表评论

登录... 后才能评论