w[wi].disabled = true;
w
目的:订房页面,已被预订的房间的时间段的区域td点击不弹出bootstrap模态框。
<script>
var w = document.querySelectorAll("td");
console.log(w);
for (var wi = 0, wl = w.length; wi < wl; wi++) {
var wattr = w[wi].style.backgroundColor
console.log(wattr)
if (wattr == 'yellow') {
console.log(w[wi].id)
w[wi].id = null
console.log(w[wi].id)
// w[wi].id=null
// w[wi].onclick=function(){alert(3)}
w[wi].disabled = true;
// console.log(w[wi].attributes['data-target'])
// w[wi].attributes['data-target'].value=null
// console.log(w[wi].attributes['data-target'])
}
}
</script>

w[wi].disabled = true;的更多相关文章
- disabled="true" 的标签元素不可提交
把jsp页面的input 标签设置成不可编辑: <input name="Id" value="${order.Id}" readOnly=&qu ...
- 针对标签中设置 disabled="true",$("#id").serialize()获取不到value的解决方法
今天给<select>增加disabled="true", 发现$("#form").serialize()的结果不包含select标签的值,解决办 ...
- 关于Angular2与蚂蚁的NG-ZOORO一同开发时[disabled]="true"动态绑定失效的解决方法
在使用Angular2与蚂蚁的NG-ZOORO一同开发时,当我们的表单使用的是formControlName="value"时[disabled]="true" ...
- w[wi].getAttribute('wattr')
w 将数据库的不同数值寄存到自定义的不同属性上,避免通过寄存到同一id属性上的字符串处理.
- 解决[disabled]="true"与formControlName冲突
import { FormBuilder } from '@angular/forms'; form; constructor(private fb: FormBuilder) { this.form ...
- green rgb(255, 102, 0) #FF6600
w通过元素背景色定位元素,改变其属性. style="background-color: #FF6600" <script> var w = document.quer ...
- timepicker php strtotime 8hours
https://jqueryui.com/datepicker/ w timepicker datepicker 日期 时间 选择器 <script src="static/jquer ...
- js和jquery设置disabled属性为true使按钮失效
设置disabled属性为true即为不可用状态. JS: document.getElementByIdx("btn").disabled=true; Jquery: $(& ...
- javascript 设置input框只读属性 获取disabled后的值并传给后台
input只读属性 有两种方式可以实现input的只读效果:disabled 和 readonly. 自然两种出来的效果都是只能读取不能编辑,可是两者有很大不同. Disabled说明该input ...
随机推荐
- 电影大全 API接口
http://www.apix.cn/services/show/29 http://www.apix.cn/services/show/112
- 使用libjpeg 压缩yuv420到jpg (内存方式)
#include <Windows.h> #include <stdio.h> extern "C" { #include <jpeglib.h> ...
- javac使用笔记
一般写java都用的IDE,今天临时要测试一下JDK安装好没,就用了一下javac,结果各种不会用 目录 javac -help查到了有javac -sourcepath,他喵的我还以为这是查找sou ...
- 回文串dp
一个字符串如果从左往右读和从右往左读都一样,那么这个字符串是一个回文串.例如:"abcba","abccba". 蒜头君想通过添加字符把一个非回文字符串变成回文 ...
- poj3261(后缀数组)
题意:给出一串长度为n的字符,再给出一个k值,要你求重复次数大于等于k次的最长子串长度........ 思路:其实也非常简单,直接求出height值,然后将它分组,二分答案......结果就出来了.. ...
- 时间同步linux和window
windows和linux都可以通过ntp服务,同步时间.
- Android——区别DVM与JVM (2)
区别DVM与JVM 1.首要差别 Dalvik: 基于寄存器,编译和运行都会更快些 JVM: 基于栈, 编译和运行都会慢些 2.字节码的区别 Dalvik: 执行.dex格式的字节码,是对.class ...
- 性能加速 - 开启opcache
说明 PHP 5.5+版本以上的,可以使用PHP自带的opcache开启性能加速(默认是关闭的).对于PHP 5.5以下版本的,需要使用APC加速,这里不说明,可以自行上网搜索PHP APC加速的方法 ...
- 素数 + 背包 - SGU 116. Index of super-prime
Index of super-prime Problem's Link Mean: 如果一个素数所在的位置还是素数,那么这个素数就是超级素数,比如3在第2位置,那么3就是超级素数. 现在给你一个数,求 ...
- 数论 - SGU 107 987654321 problem
987654321 problem Problem's Link Mean: 略 analyse: 这道题目是道简单题. 不过的确要好好想一下: 通过简单的搜索可以知道,在N<9时答案一定为0, ...