国外节点加速器_加速器国外节点_cdn国外节点加速器
最编程
2024-08-01 09:52:12
...
1、jquery 获取元素(父节点,子节点,兄弟节点)
$("#test1").parent(); // 父节点
$("#test1").parents(); // 全部父节点
$("#test1")....parents(".mui-content");
$("#test").children(); // 全部子节点
$("#test").children("#test1");
$("#test").contents...(); // 返回#test里面的所有内容,包括节点和文本
$("#test").contents("#test1");
$("#test1").prev(); // 上一个兄弟节点
$("#test1...").prevAll(); // 之前所有兄弟节点
$("#test1").next(); // 下一个兄弟节点
$("#test1").nextAll(); // 之后所有兄弟节点
$("#test1...").siblings(); // 所有兄弟节点
$("#test1").siblings("#test2");
$("#test").find("#test1");
2、元素筛选
// 以下方法都返回一个新的