Forum Discussion
If you're working with a custom component, I'd suggest putting JavaScript snippets in the @liaAddScript macro. This will place the script near the end of the page so that it loads after all of the core libraries. What's likely happening is that the code you added is trying to use the jQuery methods before it's been setup.
Here's an example of using @liaAddScript:
Thank you, that seems to have taken care of the error and your suspiciouns were correct indeed. Now I get another error instead ...
- Uncaught Cannot find tooltip for [object Object] lia-scripts-body-min.js:83
- Tooltip.$.extend.showlia-scripts-body-min.js:83
- (anonymous function)lia-scripts-body-min.js:81
- jQuery.event.special.(anonymous function).handlelia-scripts-common-min.js:203
- jQuery.event.dispatchlia-scripts-common-min.js:183
- elemData.handle.eventHandle
- AdamN12 years agoKhoros Oracle
If your community doesn't already have the tooltip jQuery library loaded, you may have to add that as well.
The snippet above is not the full implementation details, but rather was just a sample to point the topic author in the right direction. If you're having trouble implementing this type of customization yourself, Lithium has a Professional Services team that can work with you to scope out your requirements and perform the necessary implementation for you. If you're interested in that, please file a case via the support portal so that you can get into contact with someone from the Professional Services team.
- irach1510 years agoMaven
jQuery library is loaded, console.log is typing a test message...
However, I got same error message as another person in this post from 20012...
Uncaught Cannot find tooltip for [object Object]
$.extend.show @ lia-scripts-body-min.js:395
(anonymous function) @ lia-scripts-body-min.js:393
jQuery.each.jQuery.event.special.(anonymous function).handle @ lia-scripts-common-min.js:203
jQuery.event.dispatch @ lia-scripts-common-min.js:183
jQuery.event.add.elemData.handle.eventHandle @ lia-scripts-common-min.js:151
.......................
any updates on this???
Related Content
- 9 months ago
- 2 years ago
- 2 years ago