(function () {// fill the lower part with the upper content $ ("# bottom" ).html ($ ("# top" ).html ()); // bind a mouse event to the displayed area $ ("# content "). bind ("mouseover", function () {StopScroll () ;}); $ ("# content "). bind ("mouseout", function () {StartScroll () ;}); // start the timer and start the rolling function StartScroll () {objInterval = setInterval ("verticalloop ()", interval);
Copy Code code as follows:
var str= "Customer service";
var objft=new floatt ("FloatMenu1", str,942,137,125,200,80,10);
Objft.floatrun ();
JS follows the scroll bar scroll floating
pobjname:html Element ID
ptext:html element content
Others see for themselves
function Floatt (pobjname,ptext,pstmnleft,pst
This is relatively simple, make a record.
Create a nested node, let the outer node produce a scroll bar, and then use Offsetwidth-clientwidth to get the scroll bar width. Note that to avoid page jitter, you can set the outer elements position:absolute and Visibility:hidden
Reference:
Copy Code code as follows:
Remember last year, csdn was named the simplest seamless rolling.
Program , Only five lines are required.
Code The post has aroused a heated discussion!
At that time, I tried to use this principle to implement smooth scrolling. In csdn, I published an article titled modifying the five lines of code in the current version to implement endless scrolling Code.
This article mainly introduces the example code of a rolling effect to the right of a js image. If you need it, refer to the example below.
Style
The Code is as follows:
# P_left {float: left; width: 60px; height: 86px ;}# StarScroll {width: 843px; height: 188px; margin-left: 15px; margin-right: 15px; padding-top: 9px; overflow: hidden; border: 1px solid red; float: left ;}# StarScroll # contentScroll {w
This article mainly shares the core code of jQuery products that continuously scroll down. If you need it, refer to the core code below:
The Code is as follows:
$ (Function (){Var _ BuyList = $ ("# buyList ");Var Trundle = function (){_ BuyList. prepend (_ BuyList. find ("li: last" margin listing .css ('margintop
Many of my friends asked me about the code of the scroll navigation menu at the top of the Blog in various ways. In fact, there is nothing special, but since there is a need, I will sort out this part of the code for your reference.Copy codeThe Code is as follows:
The following small make up will bring you a DIV rolling with the scroll bar to implement the Code [recommended ]. I think it is quite good. Now I will share it with you and give you a reference. Let's take a look at the small editor. I remember it was troublesome to write such code before. Now JQuery is much simpler, just a few lines of
This article mainly introduces some reference values for image rotation, mouse wheel scaling, mirroring, and switching image js Code, if you are interested, you can refer to the examples in this article to show you the effects of image rotation, mouse wheel scaling, image, and image switching, and provide detailed code, the content is as follows:
Code:
Imag
Query the relevant information, Div does not automatically scroll properties, can only simulate the scrolling mouse to the actual desired effect.
The crucial part is here: Div.scrolltop = div.scrollheight;
The following is a detailed implementation of the streamlined code:
Copy Code code as follows:
The js Code returned from the js scroll bar to the top is relatively simple and suitable for learning. Although smooth processing is not good, It is very suitable for learning.
The Code is as follows:
This article mainly introduces the js control of Multi-chart rolling switching between left and right. It is very useful Code and is recommended to you. If you need it, you can refer to it. This article describes how to implement a rolling switch between the left and right sides of the js control multi-chart. Share it with you for your reference. The details are as follows:
This is a pure js model that enables automatic and smooth scrolling of images
A few short jquery codes implement an image scroll up switch. For more information, see. Description of the animate () parameter:
The animate () method executes the Custom Animation of the CSS property set.
This method uses the CSS style to change an element from one state to another. The CSS attribute value is gradually changed, so that you can create an animation effect.
Only numeric values can be used to create animations (such as "margin: 30px ").
When we do a ListView batch load, we need to call Setonscrolllistener for the ListView (Specific code visible in my previous blog)However, we will find that the ListView does not scroll when running the program, so why does the system call the Onscroll method? (Supplemental: onscrollstatechanged is not called at this time)Let's look at Setonscrolllistener source code
Small weave to teach you JS special effects Drag the scroll bar can score effects, small series feel pretty good, use the time may need to asp/php or other language with value and write to the database, this is the realization of the foreground.
Directly on the code to see the magic of JS!
The above is a small set of JS to introduce the implementation of the drag-and-drop performance
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.