I'm trying to use a subset of the prototype javascript library
(MooFx) with DNN and am looking for the best way to achieve this.
The javascript needs to be placed in the <head> section of the document. I believe this should be possible making a change to the skin as here:
http://forums.asp.net/thread/1295975.aspxThe thing I don't like about this is that I will have to load the javascript on my other pages that don't need this feature. I guess my other option would be to create a different skin for this one page, but that seems like a waste.
I've been messing around with trying to place the javascript in the page settings..
Page Settings -> Advanced Settings -> Page Header Tags
This is the javascript in the Head Tag after I do this<script type="text/javascript" src="/dotnetnuke/Portals/0/Skins/CVAR/prototype.lite.js"></script>
<script type="text/javascript" src="/dotnetnuke/Portals/0/Skins/CVAR/moo.fx.js"></script>
<script type="text/javascript">
window.onload = function() {
var myStretch = document.getElementsByClassName('stretch');
var myStretcher = document.getElementsByClassName('stretcher');
var myAccordion = new fx.Accordion(myStretch, myStretcher, {opacity: true});
}
</script>
</head>
I believe my problem is where I reference the .js files. How do I access these files from the page header input box? DNN confuses me with the way relative links work.
I have enjoyed using this javascript library in my sites before DNN and would love being able to use it in DNN. Any ideas???