Alibabacloud.com offers a wide variety of articles about jquery accordion tutorial, easily find your jquery accordion tutorial information here online.
Achieve resultsImplementation steps
Mouse into Li, the box becomes wider, the other boxes become narrower, the mouse moves away from the large box and reverts to the originalImplementation steps1. Add a background to Li2. Bind the onmouseover event, mouse into Li, the box becomes wider, the other box narrows3. Remove the box and return to the original
Implementation code "Front-end" javascript+jquery for
'). Slidetoggle ();
});
$ (". Childrenli"). Click (Function (event) {
event.stoppropagation ();
$ (". Childrenli"). Removeclass (' Selectedchildrenmenu ');
$ (". Parentli"). Removeclass (' Selectedparentmenu ');
$ (this). Parents (". Parentli"). AddClass (' Selectedparentmenu ');
$ (this). addclass (' Selectedchildrenmenu ');
});
It should be noted that the list nesting, will cause event bubbling, so in the click of the submenu event to organize Bubbles, event.sto
Accordion effect is the use of a higher frequency in the project, the original project has been used Easyui, near the end of the year, try to write a
CSS Styles
Copy Code code as follows:
/* CSS Document * *
Body {
margin:0 Auto;
padding:0 Auto;
font-size:9pt;
Font-family: Microsoft James Black, XXFarEastFont-Franklin, Arial, Helvetica, Verdana, Sans-serif;
}
. accordion {
padding-left
JQuery Easyui uses the (1) foldable panel layout accordion menu, jqueryeasyui
Let's take a look at the following:
The key code is as follows:
Now, the code is over. The next article will introduce jQuery Easyui (2) methods to solve ineffective dynamic loading of foldable panels
The above section describes the layout of the
Today, we're going to use the accordion in the jquery UI, which is mainly used to achieve the folding effect, more suitable for the menu, and the accordion ... Let's take a look at the screenshot of our results:
If the drag function is missing, then our work today is nothing special, here, we introduced the jquery
Simple jQuery cxMenu accordion navigation, jquerycxmenu
Version:
JQuery v1.7 +
JQuery cxMenu v1.2
Note:
The system automatically determines whether sub-navigation exists. If yes, the link is not triggered. If no sub-navigation exists, the link is triggered.
Instance PreviewHow to load JavaScript files
CSS sty
Http://www.cssrain.cn/article.asp? Id = 1369 Create an accordion using jquery
This example describes how to use jquery to create a simple vertical accordion menu, from easy to difficult.
Step 1: set up the basic structure.
I am using the DL DT dd structure, as shown below:
Demo: http://www.cssrain.c
Recently I saw the teaching video has a lot of accordion effect, I also try to write, as a practice.Tomorrow I have a holiday, will go to find a job, do not know, my front-end road, can formally start.Rookie take-off opportunities are not, it is embarrassing.Purely Practice:EffectHtml:ulclass= "Wrap"> Liclass= "Checked"> span>Option 1span> Div>1Div> Li> Li> span>Option 2span> Div>2Div> Li> Li> span>Option
This article illustrates the implementation method of accordion picture display based on jquery. Share to everyone for your reference. The implementation methods are as follows:
The code runs as shown in the following illustration:
The index.html page code is as follows:
Copy Code code as follows:
NetherlandsBelgiumFranceGermanyEngland
Full Instance code click here Download the site
Use example of jQuery EasyUI folding panel accordion (SHARE)
1. Set class = "easyui-accordion" for the div in the collapsed panel area"
2. Add multiple div in the area. Each div is a panel (you must set the title attribute for each panel ).
3. Set the Panel property fit to true and adapt to the parent container size.
CSS and JS are two ways to implement the accordion folding menu. css tutorial
CSS3 exploitation: target pseudo class implementation. Accordion h3 + div {height: 0; overflow: hidden;/* Hide the excess part */transition: height 0.3 s hide-in;/* a special effect to expand, take 0.3s to fly slowly */}. accordion: target h3
Version:
JQuery v1.7+
JQuery Cxmenu v1.2
Precautions:
Automatically determine if there is a child navigation, there is the display does not trigger the link, none triggers the link.
Instance PreviewLoading JavaScript files using methods CSS Style structureIn addition to the necessary property settings, other styles can be set on their own./* Swipe navigation */. menu{}. Menu > li{}. m
La Feng jquery made accordion folding menu, the effect is very good! This is the previous version of the improved version, mainly jquery code improvements
Demo diagram:
Main.js
$ (function () {
var tmp = null,
$title = $ ('. Title '),
$con = $ ('. Title > UL ');
$title. Click (function () {
$ (TMP). Children (' ul '). Slideup ().
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.