<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title></title>
<script src="http://static01.baomihua.com/js/core/jquery-1.8.3.min.js?t=20150327.js"></script>
</head>
<body>
<ul id="list1">
ul
<li>
li
<span>span</span>
</li>
</ul>
<ul id="list2">
ul
<li>
li
<span>span</span>
</li>
</ul>
<script>
$('#list1').on('click', 'span', function(event) {
console.log(event.currentTarget.innerHTML)
console.log(event.target.innerHTML)
})
$('#list2').on('click', function(event) {
console.log(event.currentTarget.innerHTML)
console.log(event.target.innerHTML)
console.log($(event.target).closest('li').html())
})
</script>
</body>
</html>

closest的更多相关文章

  1. [LeetCode] Closest Binary Search Tree Value II 最近的二分搜索树的值之二

    Given a non-empty binary search tree and a target value, find k values in the BST that are closest t ...

  2. [LeetCode] Closest Binary Search Tree Value 最近的二分搜索树的值

    Given a non-empty binary search tree and a target value, find the value in the BST that is closest t ...

  3. [LeetCode] 3Sum Closest 最近三数之和

    Given an array S of n integers, find three integers in S such that the sum is closest to a given num ...

  4. ICP算法(Iterative Closest Point迭代最近点算法)

    标签: 图像匹配ICP算法机器视觉 2015-12-01 21:09 2217人阅读 评论(0) 收藏 举报 分类: Computer Vision(27) 版权声明:本文为博主原创文章,未经博主允许 ...

  5. Leetcode 16. 3Sum Closest

    Given an array S of n integers, find three integers in S such that the sum is closest to a given num ...

  6. LeetCode:3Sum, 3Sum Closest, 4Sum

    3Sum Closest Given an array S of n integers, find three integers in S such that the sum is closest t ...

  7. K closest points

    Find the K closest points to a target point in a 2D plane. class Point { public int x; public int y; ...

  8. 16. 3Sum Closest

    题目: Given an array S of n integers, find three integers in S such that the sum is closest to a given ...

  9. jquery:closest和parents的主要区别

    closest和parents的主要区别是:1,前者从当前元素开始匹配寻找,后者从父元素开始匹配寻找:2,前者逐级向上查找,直到发现匹配的元素后就停止了,后者一直向上查找直到根元素,然后把这些元素放进 ...

  10. Leetcode 3Sum Closest

    Given an array S of n integers, find three integers in S such that the sum is closest to a given num ...

随机推荐

  1. 1. 连接字符串的创建 - Lazy.Framework从零开始设计自己的ORM架构

    开发初衷 注册了博客园已经有几个月了,却从来都没有上来过,本人大概从2010年开始就开始做.NET 方向的开发. 这个是我在博客园发布的第一个帖子. 主要就是说说最近在写的一个ORM架构. 本人接触的 ...

  2. Asp.net: WebForm基础上构建Mvc的方法

    添加引用: System.Web.Routing System.Web.Abstractions System.Web.Mvc 添加文件夹: Controllers, Views,  Views / ...

  3. 前台添加jquery的引用

    注意引用的顺序. 以下两个引用,因为bxCarousel.js引用了jquery.js所以jquery.js必须在bxCarousel.js的前面.一般来说对jquery.js的引用放在前面. < ...

  4. servlet(一)

    百度百科是这样的: Servlet 是在服务器上运行的小程序.这个词是在 Java applet 的环境中创造的.虽然后者已很少被使用,但 Servlet 却发展的很好.是一般面试都会常考的知识. 维 ...

  5. xp和win 2003远程桌面强制进入命令

    xp和win 2003远程桌面强制进入命令 注意:端口号也可以不写 如果是在win 2003里面进行踢人的话可以用命令: mstsc /console /v:172.25.100.27:3389 如果 ...

  6. C#输出40以内的所有奇数程序代码

    using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Cons ...

  7. java 使用substring 截取特殊字符串的后一位或者数字

    关于截取特殊的字符串的后一位或者数字 需求:截取特殊字符为  .   后一位 String[] str = uri.split("/"); String str1 = str[st ...

  8. Android APK安装过程介绍

    课题路径:从Myfile中点击应用进行安装,到安装完成,过程分析 思想方法:在研究PreloadInstaller的时候我们直接从整个apk的文件结构入手,由整体到部分的分析:但现在整个PMS非常庞大 ...

  9. Mac os下安装pycurl

    今天在Mac OS 10.9.2下安装pycurl时候失败,出现以下问题 Using curl-config (libcurl 7.30.0) clang: error: unknown argume ...

  10. 【产品对比分析】See做了明星衣橱想做的东西?

    不断地发现.联想.思考,让学到的东西互通起来吧!  先来两张See的界面图镇楼——          See简介: See是一个专注找同款的时尚社区,主打功能是一键拍照找同款,由社区为你提供最佳商品或 ...