jQuery Tiny Scrollbar插件-刷新时无法显示所有内容 [英] jQuery Tiny Scrollbar plugin - Fails to show all content on refresh

查看:102
本文介绍了jQuery Tiny Scrollbar插件-刷新时无法显示所有内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在网站上实现了Tiny Scrollbar插件,以实现美观的div滚动.但是,当我在Safari或Chrome浏览器中刷新页面时,会发生奇怪的事情.它似乎剪辑了我的一些内容.页面刷新后会发生什么,使它的行为如此? 请查看 mettestentoft.dk

I've implemented Tiny Scrollbar plugin on a website, for good-looking div scrolling. But weird stuff happens when I refresh the page in Safari or Chrome. It seams to clip some of my content. What happens upon a page refresh, that could make it behave like this? Please have a look at mettestentoft.dk

我尝试在一个简单的测试页面上使用相同的插件,页面刷新将使该插件向div添加一个"scrollbar disable"类,同时单击链接到同一页面的链接,将使我显示正如它应该.

I've tried using the same plugin on a simple test page, where a page refresh would make the plugin add a 'scrollbar disable' class to the div, while clicking a link linking to the same page, would make i show as it should.

微小的Scrollbar插件演示似乎没有任何问题,除非我错过了.

Tiny Scrollbar plugin demopage doesn't seem to have any problems, unless I'm missing it.

所以我的问题是:为了使页面平均加载到链接页面上,我是否必须做一些jQuery的事情?

So my question is: Do I have to do something jQuery-wise, in order for a page to load equally to a linked page?

预先感谢您:)

推荐答案

您如何初始化Scrollbar插件?是$('#cases_container').tinyscrollbar();吗?

How are you initializing the Scrollbar plugin? is it $('#cases_container').tinyscrollbar();?

删除#cases_container格的设置高度.

Nodo.css行:101.

Nodo.css line: 101.

#cases_container {
    /*height: 383px;*/
    width: 550px;
    /*overflow-x: hidden;*/
    /*overflow-y: hidden;*/
    /*position: relative;*/
    /*top: -200px;*/
    /*left: 250px;*/
}

我假设这样做会弄乱它在页面上的位置,因此创建另一个容器div来应用所有相对位置等,但是将溢出隐藏在其中.

I'm assuming doing this will screw up it positioning on the page so create another container div that applys all the relative positions etc. but leave the overflow hidden out of it.

这篇关于jQuery Tiny Scrollbar插件-刷新时无法显示所有内容的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆