Home > Web Front-end > JS Tutorial > body text

Example of usage of composite attribute selector in jQuery_jquery

WBOY
Release: 2016-05-16 16:22:41
Original
1812 people have browsed it

The example in this article describes the usage of composite attribute selector in jQuery. Share it with everyone for your reference. The specific analysis is as follows:

This selector can match elements that meet multiple attribute conditions at the same time.

Grammar structure:

Copy code The code is as follows:
[selector1][selector2][selectorN]

Parameter list:

参数 描述
selector1 属性选择器。
selector2 另一个属性选择器,用以进一步缩小范围。
selectorN 任意多个属性选择器,也是用来缩小范围。

实例代码:

复制代码 代码如下:






脚本之家





 

       
  • ASP教程

  •    
  • ASP.NET教程

  •    
  • ;PHP教程

  •  

 

       
  • html教程

  •    
  • DIV CSS教程

  •    
  • jQUERY教程

  •    
  • jAVAScript教程

  •  





以上代码可以将li元素中,class属性值为“houtai”,title属性值以“p”结尾的li元素,并且其中的文本颜色设置为蓝色。

希望本文所述对大家的jQuery程序设计有所帮助。

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!