如何在滑块横幅上创建搜索?

时间:2017-08-22 12:05:12

标签: php css codeigniter

代码:

<section id="featured" class="bg">
    <div class="container">
        <div class="row">
            <div class="col-lg-12">
                <div id="main-slider" class="main-slider flexslider">
                    <ul class="slides">
                      <li>
                        <img src="<?php echo base_url(); ?>resources/img/1.jpg" alt="" />
                      </li>
                      <li>
                        <img src="<?php echo base_url(); ?>resources/img/2.jpg" alt="" />
                      </li>
                      <li>
                        <img src="<?php echo base_url(); ?>resources/img/3.jpg" alt="" />
                      </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>  
</section>

<div class="col-lg-12">
    <input type="text" name="search" id="search" placeholder="search file"/>
    <input type="submit" name="find" id="find" />
</div>

在我的索引页面中,我有一个滑块横幅,其中三个图像一个接一个地连续滑动。现在,我想在滑块中间添加搜索栏,图像可以滑动,搜索栏应该修复。我怎么能这样做?请帮帮我。

谢谢

1 个答案:

答案 0 :(得分:0)

将搜索div放在该部分内,并使其相对于

部分为绝对值
<section id="featured" class="bg">
<div class="container">
    <div class="row">
        <div class="col-lg-12">
            <div id="main-slider" class="main-slider flexslider">
                <ul class="slides">
                  <li>
                    <img src="<?php echo base_url(); ?>resources/img/1.jpg" alt="" />
                  </li>
                  <li>
                    <img src="<?php echo base_url(); ?>resources/img/2.jpg" alt="" />
                  </li>
                  <li>
                    <img src="<?php echo base_url(); ?>resources/img/3.jpg" alt="" />
                  </li>
                </ul>
            </div>
        </div>
    </div>
</div> 
<div class="col-lg-12 search_outer">
<input type="text" name="search" id="search" placeholder="search file"/>
<input type="submit" name="find" id="find" />
</div>
</section>