Advertisement
Guest User

bhson

a guest
Jan 22nd, 2010
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.94 KB | None | 0 0
  1. $(document).ready(function(){
  2. $(".gizle").click(function(){
  3. $(".gizle").animate({opacity:0}, 250).hide("slow");
  4. $(".goster").animate({opacity:1}, 250).show("normal");
  5. $(".sag-sutun").animate({marginRight:"-220px", opacity:0}, 250);
  6. $(".sol-sutun").animate({marginRight:"40px"}, 250);
  7. });
  8. $(".goster").click(function(){
  9. $(".gizle").animate({opacity:1}, 250).show("normal");
  10. $(".goster").animate({opacity:0}, 250).hide("slow");
  11. $(".sag-sutun").animate({marginRight:"30px", opacity:1}, 250 );
  12. $(".sol-sutun").animate({marginRight:"270px"}, 250);
  13. });
  14. });
  15. Herşeyi bu şekilde yaptıktan sonra, aşağıdaki gibi kodlara sahip olucaktınız;
  16. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  17. <html xmlns="http://www.w3.org/1999/xhtml">
  18. <head>
  19. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  20. <title>jQuery &#304;le "Gizle/G�ster" S�tun ve Tablo Yap&#305;m&#305;</title>
  21. <script src="jquery-1.4.min.js" type="text/javascript"></script>
  22. <script type="text/javascript">
  23. $(document).ready(function(){
  24. $(".gizle").click(function(){
  25. $(".gizle").animate({opacity:0}, 250).hide("slow");
  26. $(".goster").animate({opacity:1}, 250).show("normal");
  27. $(".sag-sutun").animate({marginRight:"-220px", opacity:0}, 250);
  28. $(".sol-sutun").animate({marginRight:"40px"}, 250);
  29. });
  30. $(".goster").click(function(){
  31. $(".gizle").animate({opacity:1}, 250).show("normal");
  32. $(".goster").animate({opacity:0}, 250).hide("slow");
  33. $(".sag-sutun").animate({marginRight:"30px", opacity:1}, 250 );
  34. $(".sol-sutun").animate({marginRight:"270px"}, 250);
  35. });
  36. });
  37. </script>
  38. <style type="text/css">
  39. .ana-tablo { overflow:hidden; position:relative; padding-bottom:10px; }
  40. .sag-sutun { width:220px; float:right; overflow:hidden; padding-right:10px; margin-right:30px; }
  41. .sag-sutun div { width:200px; padding:10px; margin-bottom:10px; /*Buradan*/-moz-box-shadow:1px 1px 5px #e4e4e4; -moz-border-radius:10px; -webkit-border-radius:10px;/*Buraya CSS3! Her taray&#305;c&#305;da �al&#305;&#351;maz!!!..*/ }
  42. .sol-sutun { margin-right:270px; padding:10px; background:#fefee0; /*Buradan*/-moz-box-shadow:1px 1px 5px #e4e4e4; -moz-border-radius:10px; -webkit-border-radius:10px;/*Buraya CSS3! Her taray&#305;c&#305;da �al&#305;&#351;maz!!!..*/ }
  43. .gizle, .goster { font-size:25px; position:absolute; top:0; right:10px; background:#000; color:#fff; padding:5px 5px 8px 5px; line-height:0.2em; cursor:pointer; overflow:hidden; /*Buradan*/-moz-box-shadow:1px 1px 5px #e4e4e4; -moz-border-radius:5px; -webkit-border-radius:5px;/*Buraya CSS3! Her taray&#305;c&#305;da �al&#305;&#351;maz!!!..*/ }
  44. .goster { display:none; }
  45. </style>
  46. </head>
  47. <body>
  48. <div class="ana-tablo">
  49. <div class="gizle">&raquo;</div>
  50. <div class="goster">&laquo;</div>
  51. <div class="sag-sutun">
  52. <div>...</div>
  53. <div>...</div>
  54. </div>
  55. <div class="sol-sutun">...</div>
  56. </div>
  57. </body>
  58. </html>
  59.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement