-
1. Re: Richfaces and Thickbox with JQuery
sergeysmirnov Feb 20, 2008 1:25 PM (in response to jucobb2)Most easiest way is using ALL for lLoadStyleStrategy:
See:
http://www.jboss.com/index.html?module=bb&op=viewtopic&t=126207
After that, the jQuery will be loaded on each you page and you just need to add thickbox.js by yourself.
Do not add one more copy of jQuery. Two of them loaded at the same time might cause unexpected glitches.
Read the second paragraph at http://livedemo.exadel.com/richfaces-demo/richfaces/jQuery.jsf. It is still important. -
2. Re: Richfaces and Thickbox with JQuery
jucobb2 Feb 20, 2008 1:41 PM (in response to jucobb2)I tried that and it still wont work with the jquery library that is included in richfaces. It doesnt do anything with the Thickbox. Is there anyway to patch in a different version of jquery into richfaces?
With thickbox all you do is set the class attribute to = thickbox. Not sure how I can get this to work. -
3. Re: Richfaces and Thickbox with JQuery
sergeysmirnov Feb 20, 2008 1:44 PM (in response to jucobb2)do you have any js error in the firebug console?
-
4. Re: Richfaces and Thickbox with JQuery
jucobb2 Feb 20, 2008 2:16 PM (in response to jucobb2)I am getting an error:
$(document).ready is not a function
http://localhost:8080/testapp/javascripts/thickbox-compressed.js
Line 10
Do I need to change $(document) to jQuery(document) in the thickbox.js?? -
5. Re: Richfaces and Thickbox with JQuery
sergeysmirnov Feb 20, 2008 5:29 PM (in response to jucobb2)I do not thing that third party extension js should be fixed in order to switch between $() and jQuery(). If so, it is a critical bug in such extension. I do not think that thickbox has it.
Try to use thickbox and jQuery, but without RichFaces. Set noConflict option and see how they work. If OK, you did something wrong with current configuration. (In general, it looks like the jQuery is loaded twice and the noConflict was ommited) -
6. Re: Richfaces and Thickbox with JQuery
jucobb2 Feb 20, 2008 5:35 PM (in response to jucobb2)I did try the noConflict and that made it not work at all. I ended up finding another library that achieved the same thing. It works without any conflicts. Thanks for your help
-
7. Re: Richfaces and Thickbox with JQuery
sergeysmirnov Feb 20, 2008 5:43 PM (in response to jucobb2)Ok. Good to know. You can submit the bug to them if you wish. noConflict is a standard jQuery mode, but not something extraordinary. All extension should take care about it.