Guest sendoh23 Posted May 10, 2007 Share Posted May 10, 2007 I have tried to implement a simple javascript to my index.tpl to enhance the look of my scroll bars but it doesnt seems to work for me. is it tpl doesnt accept javascripts? anyway heres my code <!-- BEGIN: body --> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset={VAL_ISO}" /> <title>{META_TITLE}</title> <meta name="description" content="{META_DESC}" /> <meta name="keywords" content="{META_KEYWORDS}" /> <link href="skins/{VAL_SKIN}/styleSheets/layout.css" rel="stylesheet" type="text/css" /> <link href="skins/{VAL_SKIN}/styleSheets/style.css" rel="stylesheet" type="text/css" /> <script language="javascript" src="js/jslibrary.js" type="text/javascript"></script> </head> <body> <script language="JavaScript1.2"> <!-- /*---For flat scrollbars. Colors: line1 - #ffffff, line2 - #ffffff, face1 - #c3c3fb, face2 - #c3c3fb*/ function clrBar(line,face) { with(document.body.style) { scrollbarDarkShadowColor=line; scrollbar3dLightColor=line; scrollbarArrowColor="black"; scrollbarBaseColor=face; scrollbarFaceColor=face; scrollbarHighlightColor=face; scrollbarShadowColor=face; scrollbarTrackColor="#F3F3F3"; } } function setcolor() { var w = document.body.clientWidth; var h = document.body.clientHeight; var x = event.clientX; var y = event.clientY; if(x>w) clrBar("#ffffff","#c3c3fb"); // Colors of active state else clrBar("#ffffff","#c3c3fb"); // Colors of normal state } if (document.all){ clrBar(null,null); document.onmousemove=setcolor; } //------- Source Code Generator - La Minh Khanh ------ // //------- Scrollbar Rollover Created Free At http://www.DesignerWiz.com ------ // //------- Development Resource & JavaScript Public Archive Center ------ // //------- Credits Above Must Remain In Code For Permission To Use ----- // --> </script> <div id="pageSurround"> <div id="topHeader"> <div>{SEARCH_FORM}</div> <div>{SESSION}</div> </div> <div> <div class="colLeft"> {CATEGORIES} {RANDOM_PROD} {INFORMATION} {CURRENCY} {LANGUAGE} </div> <div class="colMid"> {PAGE_CONTENT} </div> <div class="colRight"> {SHOPPING_CART} {POPULAR_PRODUCTS} {SALE_ITEMS} {MAIL_LIST} </div> </div> <br clear="all" /> {SITE_DOCS} </div> </body> </html> <!-- END: body --> hope some kind soul would help me out on this issue thanks! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.