Jump to content
  • Sign in to follow this  

    Плавная прокрутка


    Silence

    Плавная прокрутка

    Перейти к ACP > Customizations > Themes > ваша тема > edit HTML and CSS > core > front > global > clobalTemplate и найти:

    <!--ipsQueryLog-->

    после его поставит ето код:

    Спойлер
    
    <script type="text/javascript">  
     jQuery(function(){  
      $("#Go_Top").hide().removeAttr("href");  
      if ($(window).scrollTop()>="250") $("#Go_Top").fadeIn("slow")  
      $(window).scroll(function(){  
      if ($(window).scrollTop()<="250") $("#Go_Top").fadeOut("slow")  
      else $("#Go_Top").fadeIn("slow")  
      });  
    
      $("#Go_Bottom").hide().removeAttr("href");  
      if ($(window).scrollTop()<=$(document).height()-"999") $("#Go_Bottom").fadeIn("slow")  
      $(window).scroll(function(){  
      if ($(window).scrollTop()>=$(document).height()-"999") $("#Go_Bottom").fadeOut("slow")  
      else $("#Go_Bottom").fadeIn("slow")  
      });  
    
      $("#Go_Top").click(function(){  
      $("html, body").animate({scrollTop:0},"slow")  
      })  
      $("#Go_Bottom").click(function(){  
      $("html, body").animate({scrollTop:$(document).height()},"slow")  
      })  
     });  
     </script>  
    
     <a style='position: fixed; bottom: 300px; right: 1px; cursor:pointer; display:none;'  
     href='#' id='Go_Top'>  
      <i class="fa fa-chevron-up" aria-hidden="true"></i>  
     </a>  
     <a style='position: fixed; bottom: 250px; right: 1px; cursor:pointer; display:none;'  
     href='#' id='Go_Bottom'>  
      <i class="fa fa-chevron-down" aria-hidden="true"></i>  
     </a>

     

    Ето все  ... ;)

     

    AEqurhwrCU.mp4

    Sign in to follow this  


    User Feedback

    Recommended Comments

    новый медленный код

    <script type="text/javascript">  
     jQuery(function(){  
      $("#Go_Top").hide().removeAttr("href");  
      if ($(window).scrollTop()>="250") $("#Go_Top").fadeIn("slow")  
      $(window).scroll(function(){  
      if ($(window).scrollTop()<="250") $("#Go_Top").fadeOut("slow")  
      else $("#Go_Top").fadeIn("slow")  
      });  
    
      $("#Go_Bottom").hide().removeAttr("href");  
      if ($(window).scrollTop()<=$(document).height()-"999") $("#Go_Bottom").fadeIn("slow")  
      $(window).scroll(function(){  
      if ($(window).scrollTop()>=$(document).height()-"999") $("#Go_Bottom").fadeOut("slow")  
      else $("#Go_Bottom").fadeIn("slow")  
      });  
    
      $("#Go_Top").click(function(){  
      $("html, body").animate({scrollTop:0},2000)  
      })  
      $("#Go_Bottom").click(function(){  
      $("html, body").animate({scrollTop:$(document).height()},2000)  
      })  
     });  
     </script>  
    
     <a style='position: fixed; bottom: 300px; right: 1px; cursor:pointer; display:none;'  
     href='#' id='Go_Top'>  
      <i class="fa fa-chevron-up" aria-hidden="true"></i>  
     </a>  
     <a style='position: fixed; bottom: 250px; right: 1px; cursor:pointer; display:none;'  
     href='#' id='Go_Bottom'>  
      <i class="fa fa-chevron-down" aria-hidden="true"></i>  
     </a>

     

    Share this comment


    Link to comment
    Share on other sites


    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.
    Note: Your post will require moderator approval before it will be visible.

    Guest
    Add a comment...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Ваша ссылка была автоматически строена.   Отображать как обычную ссылку

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    Loading...

×
×
  • Create New...