Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Using Prototype.js with DNNUsing Prototype.js with DNN
Previous
 
Next
New Post
8/7/2006 8:49 PM
 
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.aspx

The 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???




 
New Post
8/8/2006 3:49 AM
 
hi

<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>

this is wrong because you ahve friendly urls and in the normal root this inst an issue becayse thats the correct way but in a page that is on home/detail/tabid/23/ etc

then your javascript isnt find anywhere

you need to put in the full path to the jscrip

http://yourdomain.com/
/dotnetnuke/Portals/0/Skins/CVAR/prototype.lite.js

 
New Post
8/9/2006 3:09 AM
 
Yeah nokiko, I finally figured this out later that night.  I was actually accessing the javascipt right (didn't mean to paste in the /dotnetnuke/ path though).   I still couldn't get the prototype javascript file to  work right in DNN though.  If anyone gets this working inside of DNN please let me know.
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...Using Prototype.js with DNNUsing Prototype.js with DNN


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out