нужна помощь тех кто разбирается.
Всем привет. нужна помощь в таком вопросе - можно ли как-то заставить работать табы на jquery-ui-1.8.4.custom.min.js, сейчас они на jquery.tools.min.js
Посмотреть о чем речь (табы та главной)- http://climatteh2.77.dp.ua/ вызов jquery.tools.min.js закоментирован, и табы не складываются, никак немогу заставить их сложиться при помощи jquery-ui-1.8.4.custom.min.js Может кто-то подскажет как их заставить работать? Спасибо |
1. Учитесь пользоваться поиском
Что вы все так рветесь UI использовать, 5 минут не можете потратить чтобы самим эти табы написать? <script src="http://code.jquery.com/jquery-latest.min.js"></script> <style type="text/css"> #tabs {margin: 0px auto;overflow: hidden;width: 204px;} #tabs div {border-left: 1px solid #DDD;overflow: hidden;width: 205px;height: 22px;} div a {display: block;float: left;width: 48px;border: 1px solid #DDD;border-left: none;text-align: center;text-decoration: none;} div a:hover {background: #FBFBFB;} ul {display: block;margin: 0px;padding: 0px;width: auto;height: auto;} li {border: 1px solid #DDD;border-top: none;display: none;float: left;list-style-type: none;width: 195px;height: 50px;} .display, .first {background: #EBFAFE;display: block;} </style> <script type="text/javascript"> $(function(){ $('div a').each(function(i){ $(this).click(function(){ $(this).toggleClass('display').siblings().removeClass('display first'); $('ul').each(function(){ $(this).find('li:eq('+i+')').toggleClass('display').siblings().removeClass('display first'); }); }); }); }); </script> <div id="tabs"> <div> <a class="first" href="#">1</a><a href="#">2</a><a href="#">3</a><a href="#">4</a> </div> <ul> <li class="first">#text_tab_1</li><li>#text_tab_2</li><li>#text_tab_3</li><li>#text_tab_4</li> </ul> </div> <script src="http://code.jquery.com/jquery-latest.min.js"></script> <div> <dl> <dt>Release Details</dt> <dd>Track</dd><dd>Album</dd><dd>Album</dd> </dl> <dl> <dt>Pricing Discounts</dt> <dd>Track</dd><dd>Album</dd><dd>Album</dd> </dl> <dl> <dt>Record Quality</dt> <dd>Track</dd><dd>Album</dd><dd>Album</dd> </dl> </div> <style type="text/css"> dl {border-bottom: 1px dotted #006B88;margin-top: 1px;text-align: left;width: 200px;} dt {color: #466780;cursor: pointer;font: bold 16px arial, helvetica, tahoma, verdana, sans-serif;} dd {color: #2D2D2D;font: normal 13px arial, helvetica, tahoma, verdana, sans-serif;} </style> <script type="text/javascript"> $(function(){ $('div').each(function(){ $(this).find('dd').hide(); $(this).find('dt').click(function(){ $(this).nextUntil('dt').slideToggle(); }); }); }); </script> |
код в студию!!! обязательно CSS, у UI есть дефолтные классы для CSS к которым в табах он обращается. меню слева у Вас не очень чтобы без проблем работает... юзайте Accordion (один из элементов UI)
|
Часовой пояс GMT +3, время: 21:47. |