PDA

View Full Version : conflict between Accordion Content script & Lightbox JS v2.0



ionnnnutz
02-21-2008, 09:48 AM
1) Script Title:
Accordion Content
2) Script URL (on DD):
http://www.dynamicdrive.com/dynamicindex17/ddaccordion.htm
3) Describe problem:
I use both these scripts. Separately they work just fine, but togheter on the same page... the Lightbox wont work. This is from Firebug:
element.style has no properties
[Break on this error] element.style.width = w +"px";

ddadmin
02-21-2008, 09:34 PM
This sounds like a conflict between the jQuery library used by the first script, and Prototype used by the second. If so, what you can do is follow the same procedure I mentioned in this thread (http://www.dynamicdrive.com/forums/showthread.php?t=29309). Specifically, inside ddaccordion.js, first do a search and replace, by replacing all occurences of $ with $j. Then, and only then, add the below to the top of the file:


var $j = jQuery.noConflict()

ionnnnutz
02-22-2008, 09:03 AM
Thank you !!! :) that solved my problem!!!

planetjill
02-29-2008, 02:05 PM
I had the same exact problem and was stuck for hours. So in gratitude for this fix that I registered as a forum member just to say thanks.

zguess
01-26-2009, 01:28 PM
THANK YOU GENIUS CODERS oh my goodness, a whole day i spent scowering this js file..

zguess
01-26-2009, 01:59 PM
actually, silly me jumped to conclusions when the light box worked, but accordion still does not.. any next tips?

rhodes
01-29-2009, 03:44 PM
same problem here.. lightbox running well but accordion doesn't..
please advise.. :confused:

jscheuer1
01-29-2009, 03:52 PM
Please start a new thread for a new question. Your problem may appear to be the same as someone else's, but may not be. Follow the directions for creating a new thread by including links to the script(s). Also, a link to your page can help speed up the process, as we often will need that anyway.