Jump to content
  • 0

вывод контента jQuery


sosedi
 Share

Question

Добрый день!не судите строго я новичок в Javascript.Хочу реализовать вывод контента подобным образом ссылка !Ихний код я смотрел, но мало что понял!

Пытаюсь это сделать таким образом :


<head>
<script src="js/jquery-1.2.6.js" type="text/javascript"></script>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251"/>
<title>Документ без названия</title>
</head>
<script type="text/javascript">
$(document).ready(function(){
$('#block_tarif').fadeOut();
$('.h_tarif').fadeIn();

$('div.all_tariff a.htarif').click(function(){
$('#block_tarif').fadeOut();
$('.h_tarif').fadeIn();
});
$('div.all_tariff a.rtarif').click(function(){
$('#block_tarif').fadeOut();
$('.r_tarif').fadeIn();
});

});
</script>
<style>


#big_block_tarifs{
width:950px;
border-color:#333;
border-style:dashed;
border-width:1px;
height:300px;
float:left;
}

.list_tariff li{
list-style:none;
float:left;
margin-right:5px;

}
.all_tariff{
float:left;
width:950px;
text-align:center;
border-width:1px;
border-style:dotted;

margin-bottom:30px;
height:60px;


}
#block_tarif{
width:950px;
height:250px;
border-color:#F00;
border-width:1px;
border-style:dotted;
background-color:#99;
display:none;

}
</style>
<body>
<div class="all_tariff">
<ul class="list_tariff">
<li>
<span tarif="1"><a class="htarif">11111</a></span>
</li>
<li>
<span tarif="2"><a class="rtarif">222222</a></span>
</li>
<li>
<span tarif="3"><a class="starif">333333</a></span>
</li>
</ul>
</div>


<div id="big_block_tarifs">

<div class="h_tarif" id="block_tarif">
<div class="menu_tarif">
<ul class="list_tariff">
<li>
<span tarif="1">444444</span>
</li>
<li>
<span tarif="2">55555</span>
</li>
<li>
<span tarif="3">6666</span>
</li>
</ul>
</div>
</div>

<div class="r_tarif" id="block_tarif">
<div class="menu_tarif">
<ul class="list_tariff">
<li>
<span tarif="1">7777</span>
</li>
<li>
<span tarif="2">88888</span>
</li>
<li>
<span tarif="3">99999</span>
</li>
</ul>
</div>
</div>
</div>

</body>
</html>

Подскажите как это лучше реализовать? желательно поподробней.

Заранее спасибо, приму любую критику)

Edited by sosedi
Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

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
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

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

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. See more about our Guidelines and Privacy Policy