开发者

Set IFrame scrollbar to top

开发者 https://www.devze.com 2023-03-20 15:56 出处:网络
I have an IFrame which I am using to horizontally scroll through a gallery. The problem is, I would like the scrollbar to b开发者_JAVA技巧e positioned at the top.

I have an IFrame which I am using to horizontally scroll through a gallery. The problem is, I would like the scrollbar to b开发者_JAVA技巧e positioned at the top. I know this is difficult to achieve but is there any trick you can pull in either css or jQuery which can get this result? Also I am using a .Net backend so if there are any controls which could help solve this in some other way, any ideas are appreciated.

My apologies if this has already been asked but I haven't found anything on this site yet explaining this.


If you control the contents of the iframe, you could use a custom jQuery scrollbar like tiny scrollbar:

http://baijs.nl/tinyscrollbar/

You could put that inside the iframe at the top, and disable the default scrollbars on the iframe.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号