How to get click event for an diabled html element
Hi:
I try using jQuery to get the click event for an diabled html element, but it seems not work.
The code snippet is following:
- <asp:TextBox ID="txbPerFName" TabIndex="1" runat="server" Width="70px" Enabled="false" CssClass="handleTooltip">
- </asp:TextBox>
- $(".handleTooltip.disabled").on({
- "click": function () {
- console.log("testok");
- console.log($(this).prop("disabled"));
- if ($(this).prop("disabled")) {
- $(this).tooltip({ items: ".handleTooltip", content: "Check Item" });
- $(this).tooltip("option", "position", { my: "right-3 top-15", at: "left bottom" });
- $(this).tooltip("open");
- }
- },
- "mouseout": function () {
- console.log("testdisableok");
- if ($(this).prop("disabled")) {
- $(this).tooltip("disable");
- }
- }
- });
Is that possible for jQuery to get the click event for an diabled html element?
Thanks a lot.