数据切换标题重置不重置文本
data-toggle title reset not resetting text
我在div上设置一个工具提示,如下所示;(坦率地说,我不确定为什么要这样做,但我看到一个片段使用了这个,它的工作方式是我喜欢的)
<div id="termsandconditions" class="col-xs-6" data-toggle="tooltip" title="Agree to the terms to enable the form">
<a href="#modal-terms" data-toggle="modal" class="register-terms">Terms</a>
<label class="switch switch-primary" >
<input type="checkbox" id="register-terms" name="register-terms">
<span></span>
</label>
</div>
更新这会产生一个样式的模态工具提示弹出,我想在点击事件中改变它的文本。我怀疑我无法更改文本与data-toggle属性有关。使用prop或attr会改变工具提示,但不会改变data-toggle设置的模态工具提示弹出框中的标题文本。
下面实际上添加了一个工具提示,但不改变原来的工具提示弹出
中的文本 $("#termsandconditions").dialog("option", "title", "De-selecting terms will disable the form");
$('#termsandconditions').prop('title', 'De-selecting terms will disable the form');
$('#termsandconditions').attr('data-original-title', 'De-selecting terms will disable the form');
$('#termsandconditions').attr('title', 'De-selecting terms will disable the form');
相关文章:
- 使用jQuery重置文本,同时存在AJAX调用
- 我可以重置文本输入而不清除它吗
- Ng模型在AngularJS中重置文本区域后未更新
- 从客户端(jQuery或JavaScript)设置ASPXGredView设置文本标题
- 在 JavaScript 中重置文本区域高度
- 阻止按钮重置文本框值
- 阻止重置文本区域
- 输入后重置文本区域
- Extjs组合框在存储区未加载任何结果时保持重置文本值
- 使用javascript重置文本框密码
- 当提交按钮时,Javascript没有重置文本框中的内容
- 数据切换标题重置不重置文本
- 在asp.net中使用javascript通过客户端重置文本框
- 设置和重置文本点击按钮jquery
- 逐行读取本地文本标题,将行存储在数组中
- JQuery-OnKeyPress输入文本标题大小写
- 如何重置文本框并使文本框中的值等于“0”"(或空白)?(javascript)
- 将文本/标题添加到缩略图滑块
- 在Safari中重置文本框值
- Firefox 不会在您重新加载页面时自动重置文本区域值