EasySlider is a jQuery-based, powerful, simple, and easy-to-use sliding door plug-in.

Source: Internet
Author: User

Easy Slider is a sliding door plug-in that supports any image or content. It slides horizontally or vertically when clicked. It has a series of rich parameter settings and can be fully controlled through CSS. Therefore, basically you only need to link this plug-in file, set the content, and then style CSS.

EasySlider Functions
Supports horizontal or vertical sliding
Supports automatic scrolling.
Continuous sliding
"Last screen" and "Next screen button"
"To the first screen" and "last screen" buttons
Hidden Control
Optional control button surround tag
Multiple sliding doors are supported on the same page.
You can set the sliding speed, automatic or pause interval, and so on.

EasySlider usage

1. First, html Tag
Copy codeThe Code is as follows:
<Div id = "slider">
<Ul>
<Li> content here... </li>
<Li> content here... </li>
<Li> content here... </li>
...
</Ul>
<Span id = "prevId"> <a href = "javascript: void (0);"> previous </a> </span>
<Span id = "nextBtn"> <a href = "javascript: void (0);"> Next </a> </span>
</Div>

Note: The content in each li is a sliding layer, and the following span is used for sliding navigation.
2. Call the jquery Library and the EasySlider plugin.
Copy codeThe Code is as follows:
<Script type = "text/javascript" src = "/js/jquery. js"> </script>
<Script type = "text/javascript" src = "/js/easySlider. js"> </script>

Note: Before 3. initialize the plug-in code
Copy codeThe Code is as follows:
<Script type = "text/javascript">
$ (Document). ready (function (){
$ ("# Slider"). easySlider ({
PrevText: 'previous slide ',
NextText: 'Next slide ',
Orientation: 'vertical'
});
});
</Script>

Note: The # sidebar corresponds to the CSS selector of the div element in the HTML Tag, indicating that the script is applied to this layer. You can also use the class name, which is similar
$ (". List ").
. Easyslider has many parameters. For more information, see the author's original article.
4. CSS style Definition
Copy codeThe Code is as follows:
# Slider ul, # slider li {
Margin: 0;
Padding: 0;
List-style: none;
}
# Slider, # slider li {
Width: 500px;
Height: 200px;
Overflow: hidden;
}
Span # prevBtn {}
Span # nextBtn {}

Note: styles are made based on your own needs.
In this case, OK.

DEMO of EasySlider

Default settings (only Flip left and right)
Default settings (number page below)

Related Article

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.