I don't see why not, though I may be missing something. Here's what I'd do:
Using a text only editor like NotePad, open up both scripts. Make sure word wrap is off for both files. Now, the jquery-1.2.2.pack.js code would probably need to come before the ddaccordion.js code, so I would add a few blank lines at the end of the jquery-1.2.2.pack.js file, and then copy and paste the entire contents of the ddaccordion.js file to the bottom of the jquery-1.2.2.pack.js file. Save it as - say:
ddaccordion_with_jquery-1.2.2.pack.js
Then you would need just one external script call for it on your page, replace:
Code:
<script type="text/javascript" src="jquery-1.2.2.pack.js"></script>
<script type="text/javascript" src="ddaccordion.js">
/***********************************************
* Accordion Content script- (c) Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Visit http://www.dynamicDrive.com for hundreds of DHTML scripts
* This notice must stay intact for legal use
***********************************************/
</script>
with:
Code:
<script type="text/javascript" src="ddaccordion_with_jquery-1.2.2.pack.js">
/***********************************************
* Accordion Content script- (c) Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Visit http://www.dynamicDrive.com for hundreds of DHTML scripts
* This notice must stay intact for legal use
***********************************************/
</script>
Bookmarks