Advertisement
MrPauloeN

Wysuwane okienko z boku HTML

May 10th, 2017
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 0.75 KB | None | 0 0
  1. <html>
  2.     <head>
  3.         <title>Ehhh</title>
  4.     </head>
  5.     <style>
  6.         #okienko {
  7.             width: 400px;
  8.             height: 400px;
  9.             background: yellow;
  10.             float: right;
  11.             position: fixed;
  12.             right: -300px;
  13.         }
  14.     </style>
  15.     <body>
  16.         <div id="okienko"></div>
  17.         <script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
  18.         <script>
  19.             $('#okienko').hover(function(){
  20.                  $(this).animate({
  21.                     right: "0px"
  22.                 }, 500)
  23.             }, function(){
  24.                 $(this).animate({
  25.                     right: "-300px"
  26.                 }, 500)
  27.             });
  28.         </script>
  29.  
  30. </body>
  31. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement