2014-02-15 165 views
0

如何隱藏使用javascript的圖像滑塊?我想在第一次加載時顯示此橫幅並希望用按鈕或「a」標記隱藏此橫幅。如果訪問者不想再次看到橫幅,他們可以隱藏橫幅。Javascript隱藏橫幅滑塊

這裏我的代碼

<div class="bootslider" id="bootslider"> 
     <!-- Bootslider Loader --> 
     <div class="bs-loader"> 
      <img src="img/loader.gif" width="31" height="31" alt="Loading.." id="loader" /> 
     </div> 

     <div class="bs-container"> 

      <!-- Bootslider Slide --> 
      <div class="bs-slide active" data-animate-in="swing" data-animate-out="magic"> 
       <div class="bs-foreground"> 
        <div class="text-center text-white" data-x="420" data-y="144" data-speed="400" data-animate-in="fadeInDown" data-delay="400"> 
         <h1 class="banner_text1">TEXT<br> 
     MINING <br> 
     ENGINE</h1> 
         <p class="hidden-xs banner_text2"> 
          TEXT SENTIMENTAL ANALYSIS 
         </p> 
        </div> 
        <div class="text-center"> 
         <div class="text-center" style="position:absolute; width:43.75%; margin-left:28.125%;"> 

          <img class="banner_img_imac" style="z-index:0" data-animate-in="fadeInDown" data-delay="800" src="img/template-product-1-imac.png" alt="iMac" class="image-layer" /> 
         </div> 
        </div> 

       </div> 
       <div class="bs-background"> 
        <img src="img/template-product-1.jpg" alt="" /> 
       </div> 
      </div> 
      <!-- /Bootslider Slide --> 





     </div> 


     <!-- Bootslider Progress --> 
     <div class="bs-progress progress"> 
      <div class="progress-bar wet-ashpalt"></div> 
     </div> 
     <!-- /Bootslider Progress --> 

     <!-- Bootslider Thumbnails --> 
     <div class="bs-thumbnails text-center text-wet-ashpalt"> 
      <ul class=""></ul> 
     </div> 
     <!-- /Bootslider Thumbnails --> 

     <!-- Bootslider Pagination --> 
     <div class="bs-pagination text-center text-wet-ashpalt"> 
      <ul class="list-inline"></ul> 
     </div> 
     <!-- /Bootslider Pagination --> 

     <!-- Bootslider Controls --> 
     <div class="text-center"> 
      <div class="bs-controls"> 
       <a href="javascript:void(0);" class="bs-prev wet-ashpalt"><img src="images/arrow_left.png"></a> 
       <a href="javascript:void(0);" class="bs-next wet-ashpalt"><img src="images/arrow_rit.png"></a> 
      </div> 
     </div> 
     <!-- /Bootslider Controls --> 

    </div> 
+0

$(「#bootslider」)。hide()? – advncd

回答

0

請搜索計算器之前,如果你想permenetly隱藏

猜你正在尋找THIS

當然

你必須添加一些到DB 否則它會每次只要會話刷新:)

+0

我已經嘗試過。但是我的橫幅在點擊時不會隱藏。我的是一個引導頁面。 – Dhanil

+0

你確定你有正確的選擇? – Dwza

+0

是啊!無論如何,我已經嘗試過與另一個JavaScript。 itz現在工作。感謝兄弟的評論。 – Dhanil