<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
   
</head>
<body>
 
<table border="1">
    <tr onclick="fn()">
        <td id="t1">取消了事件</td>
        <td >点我,我没取消</td>
        <td id="t2">取消了事件</td>
    </tr>
</table>
 
 
  <script type="text/javascript">
 
      function stopBubble(e) {
          if (e && e.stopPropagation) {
              e.stopPropagation();
          }
          else {
              window.event.cancelBubble = true;
          }
      }
     
      document.getElementById('t1').onclick = function (e) {
          stopBubble(e);
      }
      document.getElementById('t2').onclick = function (e) {
          stopBubble(e);
      }
      function fn() {
          alert('s');
      }
 
    </script>
</body>
</html>
 
<tr>
<td width="102" style="border-right-style:none">隐藏右边框</td>
<td width="119" style="border-left-style:none">隐藏左边框</td>
</tr>
<tr>
<td style="border-top-style:none">隐藏上边框</td>
<td style="border-bottom-style:none">隐藏下边框</td>
</tr>

阻止冒泡 table表格取消选中最后一列的更多相关文章

  1. jquery table表格 获取选中的某一行和某一列的值

    table class="table table-hover" id="test123"> <tr> <th width="4 ...

  2. table 表格固定表头和第一列、内容可滚动

    整理了下: <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" c ...

  3. JS+CSS - table 表格固定表头和第一列、内容可滚动 (转载)

    <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content ...

  4. table表格超出部分显示省略号

    做table表格时,某一列字数比较多,希望超出宽度的部分以省略号显示 设置table的布局 默认automatic 以表格内容显示相应宽度 改成fixed 以表格列宽显示内容 table{    ta ...

  5. bootstrap table表格属性、列属性、事件、方法

    留存一份,原文地址http://bootstrap-table.wenzhixin.net.cn/zh-cn/documentation/ 表格参数 表格的参数定义在 jQuery.fn.bootst ...

  6. 前端之 JS 实现全选、反选、取消选中

    需求 制作如下可选表格,实现“全选”.“反选”.“取消”功能 代码示例 <!DOCTYPE html> <html lang="zh-CN"> <he ...

  7. ElementUI的Table表格添加自定义头CheckBox多选框

    在ElmentUI的Table表格组件中,也许你会使用type为selection值的多选框功能,但是此时设置的label属性不生效,不能设置标题名称:有时候我们的需求就是要添加标题名称,那该如何处理 ...

  8. vue ele table表格 设置只能勾选一个

    table 更改属性设置: <el-table ref="multipleTable" :data="tableData" tooltip-effect= ...

  9. [转]CSS如何设置html table表格边框样式

    原文地址:http://www.divcss5.com/wenji/w503.shtml 对table设置css样式边框,分为几种情况: 1.只对table设置边框 2.对td设置边框 3.对tabl ...

随机推荐

  1. 在一个java类里,private int a; 什么时候要使用integer

    private Integer index; if(index == null) index = 0; else this.index = index; Integer有一个明显的好处,就是它能比in ...

  2. leecode刷题(3)-- 旋转数组

    leecode刷题(3)-- 旋转数组 旋转数组 给定一个数组,将数组中的元素向右移动 K 个位置,其中 K 是非负数. 示例: 输入: [1,2,3,4,5,6,7] 和 k = 3 输出: [5, ...

  3. Postman接口测试之POST、GET请求方法

    一.基础知识 1.HTTP的五种请求方法:GET, POST ,HEAD,OPTIONS, PUT, DELETE, TRACE 和 CONNECT 方法. GET请求:请求指定的页面信息,并返回实体 ...

  4. Python之路系列:面向对象初级:静态属性、静态方法、类方法

    一.静态属性 静态属性相当于数据属性. 用@property语法糖装饰器将类的函数属性变成可以不用加括号直接的类似数据属性. 可以封装逻辑,让用户感觉是在调用一个普通的数据属性. 例子: class ...

  5. SDUT OJ 数据结构实验之二叉树三:统计叶子数

    数据结构实验之二叉树三:统计叶子数 Time Limit: 1000 ms Memory Limit: 65536 KiB Submit Statistic Discuss Problem Descr ...

  6. js 原生JS实现轮播图

    <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8&quo ...

  7. error while loading shared libraies :libopencv_core_so.3.4:cannot open shared object

    TX2 上安装自己编译的opencv,使用时出现: error while loading shared libraies :libopencv_core_so.3.4:cannot open sha ...

  8. 老实pear_Excel 操作类 Spreadsheet_Excel_Writer 常用参数说明

    (如果是PHP5项目就不用往下看了,因为PHP5项目可以直接用PHPExcel,方便快捷) 手上有个PHP4的修改项目,要修改Excel的导出,然后再把导出的Excel再导入到系统里. 在导入的时候, ...

  9. Convert DataTable to List<T> where Class of List is Dynamic

    using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Da ...

  10. POJ - 3696 同余

    给定\(L\),求最小的\(x\)满足$ L|8\frac{10^x-1}{9} $ /*H E A D*/ inline ll gcd(ll a,ll b){return b?gcd(b,a%b): ...