error-when-calling-popoverxhide-or-popoverxshow-on-hover

Web Tips Q & ACategory: Krajee Pluginserror-when-calling-popoverxhide-or-popoverxshow-on-hover
dnajar asked 10 months ago

Issue when triggering via hover, I get Uncaught TypeError: Cannot read property \\\’offsetWidth\\\’ of undefined, unless I am not calling it correctly. Here is the code I am using.html <!– caller –> <div class=\\\”events\\\”> <div class=\\\”event fav-even\\\”> <a data-toggle=\\\”popover-x\\\” data-target=\\\”#popover1\\\” data-placement=\\\”top\\\” > Some text </a> </div> </div> <!– end of caller –> <!– popover container –> <div id=\\\”popover1\\\” class=\\\”popover popover-default\\\”> <div class=\\\”arrow\\\”></div> <div class=\\\”popover-content\\\”> <div class=\\\”close-popover\\\”> <i class=\\\”fa fa-times\\\”></i> </div> <div class=\\\”col-xs-5\\\”> <div> <img src=\\\”../images/wcc3/thumbs/image.jpg\\\”> </div> <div> <i class=\\\”fa fa-heart\\\”></i> <i class=\\\”fa fa-bell\\\”></i> <i class=\\\”fa fa-calendar\\\”></i> </div> </div> <div class=\\\”col-xs-7\\\”> <div class=\\\”title\\\”> Some text </div> <div class=\\\”subtitle\\\”>SubTitle<br> Some more txt</div> <div class=\\\”popover-description\\\”> some description ! </div> </div> <div class=\\\”clearfix\\\”></div> <button type=\\\”button\\\” class=\\\”btn btn-success\\\”>BUY TICKET NOW!</button> </div> </div> <!– end of popover container –> jquery $(\\\’.event\\\’).hover(function(){ $this = $(this); var target = $this.find(\\\’a\\\’).attr(\\\’data-target\\\’); $(target).popoverX(\\\’show\\\’); }, function(){ $(target).popoverX(\\\’hide\\\’); });please advice.

Login or register to contribute or comment.

Login   Register