用到哪写到哪,记录备忘
1、根据元素属性选择代码如下:
$("span[id='"+ currentDevice + "']")
2、元素属性以特定字符开始的写法:
$("input[id^='news']")
3、元素属性以特定字符结束的写法:
$("input[id$='news']")
用到哪写到哪,记录备忘
1、根据元素属性选择代码如下:
$("span[id='"+ currentDevice + "']")
2、元素属性以特定字符开始的写法:
$("input[id^='news']")
3、元素属性以特定字符结束的写法:
$("input[id$='news']")