Hello,
I am trying to add javascript to my skin specifically the onload event.
http://www.curvycorners.net/ is what I am trying to add.
Is there anyway to add code to the onload event that gets created and run by dot net nuke?
The code works on a plain load of the page but not through DNN. I think I am close, basically I just want to append to whatever else is there.
<CODE>
<script type="text/JavaScript" src="curvycorners.js"></script>
<script type="text/JavaScript">
//addEvent(window, 'load', initCorners);
function addLoadEvent(func) {
var oldonload = window.onload;
if (typeof window.onload != 'function')
{ window.onload = func; }
else {
window.onload = function() {
oldonload();
initcorners();
}
}
}
function initcorners() {
var settings = {
tl: { radius: 20 },
tr: { radius: 20 },
bl: { radius: 20 },
br: { radius: 20 },
antiAlias: true
}
/*
Usage:
curvyCorners(settingsObj, selectorStr);
curvyCorners(settingsObj, Obj1[, Obj2[, Obj3[, . . . [, ObjN]]]]);
selectorStr ::= complexSelector [, complexSelector]...
complexSelector ::= singleSelector[ singleSelector]
singleSelector ::= idType | classType
idType ::= #id
classType ::= [tagName].className
tagName ::= div|p|form|blockquote|frameset // others may work
className : .name
selector examples:
#mydiv p.rounded
#mypara
.rounded
*/
curvyCorners(settings, "#leftcolumn");
}
</script>
</CODE>