0
我想添加两个粘贴(向上和向下)页面中间的arroys,可以滚动一个网页分为几个部分。所以箭头始终位于第二部分到最后一部分的中间,并让页面向上或向下滚动。jquery sticked向上和向下箭头向上和向下
目前,我有一个按钮,带我到网页
.content-wrap section .back-to-top {
display: block;
position: absolute;
bottom: -65px;
right: 10px;
height: 36px;
width: 36px;
background: url(http://www.caddet-re.org/assets/images/Arrow_Circle_Up.gif);
text-indent: -9999px;
z-index: 2;
}
<a class="back-to-top" href="#main">Back to Top</a>
顶给我:
的STRU该部分的cture是:
<div class="content-wrap">
<section id="main">
<!--content-->
</section>
<section id="portfolio">
<!--content-->
</section>
...
</div>
有没有什么方法可以在第二部分之后显示箭头?我的意思是,在#部分#中没有显示箭头,之后它们显示出来... like'if($('selector')。hasClass('main')) { $(this).removeClass (“主要”); $(this).addClass(“hidden”); }'是否正确? – cMinor 2013-02-26 16:14:22
我更新了答案:-) – BorisD 2013-02-27 06:11:11