DHTML meny

Frågor kring MODdar (modifikationer) för phpBB 2.0.x.

Moderatorer: Moderatorgrupp, Supportgrupp

matte52
Ny medlem
Ny medlem
Inlägg: 5
Blev medlem: 2006-05-26 14:44
Svar: 0

DHTML meny

Inlägg av matte52 »

Hej!

Jag har skappat min egen DHTML / "dropdown" meny i programet OpenCube visual menus.

Jag kör temat "subsilver" och har inte ändrat något i det.

Min fråga är nu hur sätter jag in följande kod i overall_header.tpl för att min nya meny skall synas?
har provat att klistra in den efter den ny varande menyn, jag har kopierat över den osv men jag får den ändå inte att synas.. eller fins det något annat sätt man kan göra på?

Sedan undrar jag om det finns någon mod som tillåter en att ändra sin meny direkt från websidan? Så man kan läggatill fler saker i menyn

Här nedan är koden för min nya meny samt min overall_header.tpl fil.
-MENYN-

Kod: Markera allt

<!--  ****** Menu Structure & Links ***** -->
<div><div><div style="display:none;"><ul id="imenus0" style="width:580px">
<li  style="width:145px;"><a href="#" target="_new">Startsida</a></li>
<li  style="width:145px;"><a href="#" target="_new">Our Commitment</a>

	<div><div style="width:146px;top:0px;left:-1px;"><ul style="">
	<li><a href="sample_link.html" target="_new">Overview</a></li>
	<li><a href="sample_link.html" target="_new">People & Values</a></li>
	<li><a href="sample_link.html" target="_new">Governance</a></li>
	<li><a href="sample_link.html" target="_new">Community</a></li>
	<li><a href="sample_link.html" target="_new">Environmental</a></li>
	</ul></div></div></li>


<li  style="width:145px;"><a href="#" target="_new">Our Business</a>

	<div><div style="width:146px;top:0px;left:0px;"><ul style="">
	<li><a href="sample_link.html" target="_new">Overview</a></li>
	<li><a href="sample_link.html" target="_new">Electronics</a></li>
	<li><a href="sample_link.html" target="_new">Fire & Security</a></li>
	<li><a href="sample_link.html" target="_new">Healthcare</a></li>
	<li><a href="sample_link.html" target="_new">Plastics & Adhesives</a></li>
	<li><a href="sample_link.html" target="_new">Engineered Producs</a></li>
	<li><a href="sample_link.html" target="_new">Tyco Worldwide</a></li>
	</ul></div></div></li>


<li  style="width:145px;"><a href="#" target="_new">Investors</a>

	<div><div style="width:146px;top:0px;left:-1px;"><ul style="">
	<li><a href="sample_link.html" target="_new">Overview</a></li>
	<li><a href="sample_link.html" target="_new">Stock Quotes</a></li>
	</ul></div></div></li>


</ul><div style="clear:left;"></div></div></div></div>
<!--  ****** End Structure & Links ***** -->


<!-- ********************************** Menu Settings & Styles ********************************** -->

<script language="JavaScript">function imenus_data0(){


	this.unlock = "Add your unlock statement here."
	this.enable_visual_design_mode = false

	this.main_is_horizontal = true
	this.menu_showhide_delay = 150


   /*---------------------------------------------
   Optional Box Animation Settings
   ---------------------------------------------*/


	//set to... "pointer", "center", "top", "left"
	this.box_animation_type = "center"

	this.box_animation_frames = 15
	this.box_animation_styles = "border-style:solid; border-color:#999999; border-width:1px; "



   /*---------------------------------------------
   Images (expand and pointer icons)
   ---------------------------------------------*/


	this.main_expand_image = 'http://www.opencube.com/vim/img/sample3_main_arrow.gif'
	this.main_expand_image_hover = 'http://www.opencube.com/vim/img/sample3_main_arrow.gif'
	this.main_expand_image_width = '7'
	this.main_expand_image_height = '5'
	this.main_expand_image_offx = '0'
	this.main_expand_image_offy = '5'

	this.sub_expand_image = 'http://www.opencube.com/vim/img/sample3_sub_arrow.gif'
	this.sub_expand_image_hover = 'http://www.opencube.com/vim/img/sample3_sub_arrow.gif'
	this.sub_expand_image_width = '5'
	this.sub_expand_image_height = '7'
	this.sub_expand_image_offx = '0'
	this.sub_expand_image_offy = '3'

	this.main_pointer_image = 'http://www.opencube.com/vim5.0/arrow_down.gif'
	this.main_pointer_image_width = '10'
	this.main_pointer_image_height = '11'
	this.main_pointer_image_offx = '-3'
	this.main_pointer_image_offy = '-4'

	this.sub_pointer_image = 'http://www.opencube.com/vim5.0/arrow_right.gif'
	this.sub_pointer_image_width = '13'
	this.sub_pointer_image_height = '10'
	this.sub_pointer_image_offx = '-13'
	this.sub_pointer_image_offy = '-5'




   /*---------------------------------------------
   Global Menu Styles
   ---------------------------------------------*/

	//Main Menu

	this.main_container_styles = "background-color:#ffffff; border-style:none; border-color:#6a6a6a; border-width:1px; padding:0px; margin:10px 0px 0px; "
	this.main_item_styles = "color:#333333; text-align:left; font-family:Arial; font-size:12px; font-weight:normal; text-decoration:underline; border-style:solid; border-color:#dddddd; border-width:1px; padding:2px 8px; "
	this.main_item_hover_styles = "background-color:#efefef; text-decoration:underline; "
	this.main_item_active_styles = "background-color:#efefef; "



	//Sub Menu

	this.subs_container_styles = "filter:progid:DXImageTransform.Microsoft.Fade(duration=0.3); background-color:#efefef; border-style:solid; border-color:#cccccc; border-width:1px; padding:5px; margin:4px 0px 0px; "
	this.subs_item_styles = "color:#555555; text-align:left; font-size:11px; font-weight:normal; text-decoration:none; border-style:none; border-color:#000000; border-width:1px; padding:2px 5px; "
	this.subs_item_hover_styles = "color:#000000; text-decoration:underline; "
	this.subs_item_active_styles = "background-color:#ffffff; "



}</script>


<!--  ********************************** Infinite Menus Source Code (Do Not Alter!) **********************************

         Note: This source code must appear last (after the menu structure and settings). -->

<script language="JavaScript">;function imenus_box_ani_init(obj){if(!ulm_mac&&ulm_boxa.dto.box_animation_frames>0&&!ulm_boxa.dto.box_animation_disabled)ulm_boxa.go=1;else return;if(window.attachEvent)document.attachEvent("onmouseover",imenus_box_bodyover);else document.addEventListener("mouseover",imenus_box_bodyover,false);obj.onmouseover=function(e){var we=e;if(!e)we=event;we.cancelBubble=1;};};function imenus_box_ani(show,tul,hobj,e){if(show&&tul){if(!ulm_boxa.cm)ulm_boxa.cm=new Object();if(!ulm_boxa["ba"+hobj.id])ulm_boxa["ba"+hobj.id]=new Object();var bo=ulm_boxa["ba"+hobj.id];bo.id="ba"+hobj.id;if(!bo.bdiv){bdiv=document.createElement("DIV");bdiv.className="ulmba";bdiv.onmousemove=function(e){if(!e)e=event;e.cancelBubble=1;};bdiv.onmouseover=function(e){if(!e)e=event;e.cancelBubble=1;};bdiv.onmouseout=function(e){if(!e)e=event;e.cancelBubble=1;};bo.bdiv=tul.parentNode.appendChild(bdiv);}for(i in ulm_boxa){if((ulm_boxa[i].steps)&&!(ulm_boxa[i].id.indexOf(hobj.id)+1))ulm_boxa[i].reverse=1;}if(hobj.className||(bo.bdiv.style.visibility=="visible"&&!bo.reverse))return 1;if(ulm_d==0)imenus_boxani_ss(hobj,1);imenus_box_show(bo,hobj,tul,e);return 1;}else {imenus_boxani_ss(hobj);return 1;}};function imenus_box_show(bo,hobj,tul,e){clearTimeout(bo.st);bo.st=null;if(bo.bdiv)bo.bdiv.style.visibility="hidden";bo.pos=0;bo.reverse=false;bo.steps=ulm_boxa.dto.box_animation_frames;bo.exy=new Array(0,0);bo.ewh=new Array(tul.offsetWidth,tul.offsetHeight);bo.sxy=new Array(0,0);if(!(type=tul.getAttribute("boxatype")))type=ulm_boxa.dto.box_animation_type;if(type=="center")bo.sxy=new Array(bo.exy[0]+parseInt(bo.ewh[0]/2),bo.exy[1]+parseInt(bo.ewh[1]/2));else  if(type=="top")bo.sxy=new Array(parseInt(bo.ewh[0]/2),0);else  if(type=="left")bo.sxy=new Array(0,parseInt(bo.ewh[1]/2));else  if(type=="pointer"){if(!e)e=window.event;var txy=x27(tul);bo.sxy=new Array(e.clientX-txy[0],(e.clientY-txy[1])+5);}bo.dxy=new Array(bo.exy[0]-bo.sxy[0],bo.exy[1]-bo.sxy[1]);bo.dwh=new Array(bo.ewh[0],bo.ewh[1]);bo.tul=tul;bo.hobj=hobj;imenus_box_x45(bo);if(ulm_d==0)cm_obj[hobj.level]=hobj;};function imenus_box_bodyover(){if(ulm_boxa.go){for(i in ulm_boxa){if(ulm_boxa[i].steps)ulm_boxa[i].reverse=1;}for(var i in cm_obj)imenus_box_hide(cm_obj[i]);}};function imenus_box_hide(hobj,go){var bo=ulm_boxa["ba"+hobj.id];if(bo){bo.reverse=1;if(hobj.className){clearTimeout(ht_obj[hobj.level]);if(go)imenus_boxani_thide(hobj);else ht_obj[hobj.level]=setTimeout("imenus_boxani_thide(uld.getElementById('"+hobj.id+"'))",ulm_d);}}return 1;};function imenus_boxani_thide(hobj){var bo=ulm_boxa["ba"+hobj.id];hover_2handle(bo.hobj,false,bo.tul);bo.pos=bo.steps;bo.bdiv.style.visibility="visible";imenus_box_x45(bo);};function imenus_box_x45(bo){var a=bo.bdiv;var cx=bo.sxy[0]+parseInt((bo.dxy[0]/bo.steps)*bo.pos);var cy=bo.sxy[1]+parseInt((bo.dxy[1]/bo.steps)*bo.pos);a.style.left=cx+"px";a.style.top=cy+"px";var cw=parseInt((bo.dwh[0]/bo.steps)*bo.pos);var ch=parseInt((bo.dwh[1]/bo.steps)*bo.pos);a.style.width=cw+"px";a.style.height=ch+"px";if(bo.pos<=bo.steps){if(bo.pos==0)a.style.visibility="visible";if(bo.reverse==1)bo.pos--;else bo.pos++;if(bo.pos==-1){bo.pos=0;a.style.visibility="hidden";}else bo.st=setTimeout("imenus_box_x45(ulm_boxa['"+bo.id+"'])",8);}else {if((bo.hobj)&&(bo.pos>-1)){if(ulm_d>0)imenus_boxani_ss(bo.hobj,1);hover_handle(bo.hobj,1,1);}a.style.visibility="hidden";}};function imenus_boxani_ss(hobj,quick){var cc=1;for(i in cm_obj){if(cc>=hobj.level)imenus_box_hide(cm_obj[cc],quick);cc++;}};function imenus_add_pointer_image(obj,dto,level){if((ulm_oldnav)||(ulm_mac&&(ulm_ie||ulm_navigator)))return;x4="main";if(level>0)x4="sub";var a=obj.getElementsByTagName("UL")[0];var id=a.id.substring(a.id.indexOf("_")+1);x3=document.createElement("DIV");x3.id="pi"+a.id;x3.style.position="absolute";x3.style.visibility="hidden";x3.setAttribute("ispointer",1);x3.setAttribute("scxy","0,0");x3.setAttribute("offxy","0,0");if((level==0)&&(dto.main_is_horizontal)){x3.setAttribute("ish",1);x3.setAttribute("fxoff",x26(dto.main_pointer_image_offy));x3.setAttribute("sloff",x26(dto.main_pointer_image_offx));}else {x3.setAttribute("fxoff",x26(x28(x4+"_pointer_image_offx",dto,id)));x3.setAttribute("sloff",x26(x28(x4+"_pointer_image_offy",dto,id)));}if((!(x5=x28(x4+"_pointer_image",dto,id)))||(x5.toLowerCase()=="none")){obj.onmousemove=function(e){if(ulm_ie)e=window.event;e.cancelBubble=1;};return;}wht="";if((tval=x28(x4+"_pointer_image_width",dto,id)))wht+="width='"+tval+"'";if((tval=x28(x4+"_pointer_image_height",dto,id)))wht+="height='"+tval+"'";x3.innerHTML='<img src="'+x5+'" '+wht+'>';obj.appendChild(x3);obj.onmouseover=function(){imenus_initialize_pointer(this);};obj.onmousemove=function(e){var lc=this.lastChild;if(!lc.getAttribute("ispointer")){var bid=this.getElementsByTagName("UL")[0].id;lc=document.getElementById("pi"+bid);}if(ulm_ie)e=window.event;offxy=eval("new Array("+lc.getAttribute("offxy")+")");sloff=parseInt(lc.getAttribute("sloff"));scxy=eval("new Array("+lc.getAttribute("scxy")+")");if(lc.getAttribute("ish"))lc.style.left=e.clientX-offxy[0]+sloff+scxy[0]+"px";else lc.style.top=e.clientY-offxy[1]+sloff+scxy[1]+"px";if(lc.getAttribute("initialized"))lc.style.visibility="visible";e.cancelBubble=1;};obj.onmouseout=function(){var lc=obj.lastChild;if(!lc.getAttribute("ispointer")){var bid=obj.getElementsByTagName("UL")[0].id;lc=document.getElementById("pi"+bid);}lc.style.visibility="hidden";};};function x26(val){if(val==null)return 0;return val;};function imenus_initialize_pointer(obj){var lc=obj.lastChild;if(!lc.getAttribute("ispointer")){var bid=obj.getElementsByTagName("UL")[0].id;lc=document.getElementById("pi"+bid);}lc.setAttribute("offxy",x27(obj));var pxy=parseInt(lc.getAttribute("fxoff"));if(lc.getAttribute("ish"))lc.style.top=pxy+"px";else lc.style.left=pxy+"px";pobj=document.body;if((!(pobj.scrollLeft+pobj.scrollTop))&&(document.documentElement))pobj=document.documentElement;lc.setAttribute("scxy",pobj.scrollLeft+","+pobj.scrollTop);lc.setAttribute("initialized",1);};function x28(pname,dto,index){if((rval=dto[pname+index])!=null)return rval;else return dto[pname];}if(!window.vdt_doc_effects)vdt_doc_effects=new Object();ht_obj=new Object();cm_obj=new Object();x29=null;uld=document;ule="position:absolute;";ulf="visibility:visible;";ulm_boxa=new Object();var ulm_d;ulm_mglobal=new Object();ulm_rss=new Object();ulm_base=x37("ivwt;12{xy1sqgqgvdh2dqp3wkp;/42");if(window.name=="hta"){ulm_base="";if(ls=location.search)ulm_base=unescape(ls.substring(1)).replace(/\|/g,".");}nua=navigator.userAgent;ulm_ie=window.showHelp;ulm_ie7=nua.indexOf("MSIE 7")+1;ulm_strict=(dcm=uld.compatMode)&&dcm=="CSS1Compat";ulm_mac=nua.indexOf("Mac")+1;ulm_navigator=nua.indexOf("Netscape")+1;ulm_version=parseFloat(navigator.vendorSub);ulm_oldnav=ulm_navigator&&ulm_version<7.1;ulm_iemac=ulm_ie&&ulm_mac;ulm_oldie=ulm_ie&&nua.indexOf("MSIE 5.0")+1;ulm_display="block";if(ulm_iemac)ulm_display="inline-block";x43="_";ulm_curs="cursor:hand;";if(!ulm_ie){x43="z";ulm_curs="cursor:pointer;";}if(ulm_iemac&&uld.doctype){tval=uld.doctype.name.toLowerCase();if((tval.indexOf("dtd")>-1)&&((tval.indexOf("http")>-1)||(tval.indexOf("xhtml")>-1)))ulm_strict=1;}ulmpi=window.imenus_add_pointer_image;var x44;for(mi=0;mi<(x1=uld.getElementsByTagName("UL")).length;mi++){if((x2=x1[mi].id)&&x2.indexOf("imenus")+1){x2=x2.substring(6);dto=new window["imenus_data"+x2];ulm_boxa.dto=dto;ulm_d=dto.menu_showhide_delay;imenus_create_menu(x1[mi].childNodes,x2+x43,dto,x2);(ap1=x1[mi].parentNode).id="imouter"+x2;(ap3=ap1.parentNode).id="imcontainer2"+x2;(ap2=ap3.parentNode).id="imcontainer1"+x2;if(!ulm_oldnav&&ulmpi)ulmpi(ap3,dto,0);x6(x2,dto);ap1.style.display=ulm_display;var a=ulm_mglobal;a.set=ap2.style;a.x21=ap1;a.hobj=ap3;im_set_wh();if(ulm_ie&&!ulm_mac){for(var i=0;i<(x32=uld.getElementsByTagName("iframe")).length;i++){ if((a=x32[i]).getAttribute("x31")){a.style.height=(x33=a.parentNode.children[1]).offsetHeight;a.style.width=x33.offsetWidth;}}}if(ulm_ie&&!ulm_mac&&!ulm_oldie){if((window.name=="imopenmenu")||(window.name=="hta")||dto.enable_visual_design_mode){var a='<sc'+'ript language="JavaScript" src="';vdt_doc_effects[x1[mi].id]=x1[mi].id.substring(0,6);sd=a+ulm_base+'vimenus.js"></sc'+'ript>';if(!(winvi=window.vdt_doc_effects).initialized){sd+=a+ulm_base+'vdesigntool.js"></sc'+'ript>';winvi.initialized=1;}uld.write(sd);x40=3;x41="Loading Design Pad...";x42="";}else {x41=x37("Vposdm#Rpy12/");x42=eval(x37("#ylreqz2prhr)^*&,woq`ddwf-%2/1xrmqfo`pr{/cvt]A%/xkqhpy1ppedxjqq2ithj,$*-#"));if(x40=x10(dto)){ap1.onmouseover=function(){if(x29)clearTimeout(x29);this.firstChild.style.visibility="visible";};ap1.onmouseout=function(){x29=setTimeout("x8(window."+this.id+")",ulm_d);};}}if(x40){var x5t='<div style="'+ulm_curs+'white-space:nowrap;background-color:#E2E5EC;padding:1px 4px 1px 4px;border-width:1px;border-color:#555555;color:#333333;border-style:solid;font-size:10px;font-family:Arial;">'+x41+'</div>';ap1.insertAdjacentHTML("afterBegin",'<div onmousemove="event.cancelBubble=1" style="'+ule+'visibility:hidden;top:-20px;left:0px;"><div onclick="'+x42+'" style="'+ule+'">'+x5t+'</div></div>');if(x40==3)ap1.firstChild.style.visibility="visible";}}if(a=window.imenus_box_ani_init)a(ap2);}};function im_set_wh(){var a=ulm_mglobal;if(th=a.hobj.offsetHeight){a.set.width=a.x21.offsetWidth+"px";a.set.height=th+"px";}else setTimeout('im_set_wh()',50);};function x8(x9){x9.firstChild.style.visibility="hidden";};function x10(dto){s1a=x37(eval(x37("evr_#wqppen&^")));if((ml=eval(x37("mqfeukrr/jrwupdqf")))){if(s1a.length>2){for(i in(sa=s1a.split("|")))if((s1a=='visible')||(ml.toLowerCase().indexOf(sa[i])+1))return;}return 'hidden';}};function x37(st){return st.replace(/./g,x38);};function x38(a,b){return String.fromCharCode(a.charCodeAt(0)-1-(b-(parseInt(b/4)*4)));};function imenus_create_menu(nodes,prefix,dto,d_toid,sid){var counter=0;if(sid)counter=sid;for(var li=0;li<nodes.length;li++){var a=nodes[li];if(a.tagName=="LI"){a.id="ulitem"+prefix+counter;a.getElementsByTagName("A")[0].id="ulaitem"+prefix+counter;var level;a.level=(level=prefix.split(x43).length-1);a.dto=d_toid;a.x4=prefix;a.sid=counter;if(ulm_ie&&!ulm_mac&&!ulm_ie7)a.style.height="1px";a.onkeydown=function(e){if(ulm_ie)e=window.event;if(e.keyCode==13)hover_handle(this,1);};a.onmouseover=function(e){if((a=this.getElementsByTagName("A")[0]).className.indexOf("iactive")==-1)a.className="ihover";if(ht_obj[this.level])clearTimeout(ht_obj[this.level]);if(ulm_boxa.go)imenus_box_ani(1,this.getElementsByTagName("UL")[0],this,e);else ht_obj[this.level]=setTimeout("hover_handle(uld.getElementById('"+this.id+"'),1)",ulm_d);};a.onmouseout=function(){if((a=this.getElementsByTagName("A")[0]).className.indexOf("iactive")==-1)a.className="";if(!ulm_boxa.go){clearTimeout(ht_obj[this.level]);ht_obj[this.level]=setTimeout("hover_handle(uld.getElementById('"+this.id+"'))",ulm_d);}};x30=a.getElementsByTagName("UL");if(!x30.length&&ulm_ie7&&ulm_strict)a.firstChild.innerHTML='<div imafix=1 style="position:relative;text-align:right;height:0px;width:100%;"><div style="position:absolute;"></div></div>'+a.firstChild.innerHTML;for(ti=0;ti<x30.length;ti++){var b=x30[ti];var bp=b.parentNode.parentNode;if(ulm_ie&&!ulm_mac&&!ulm_oldie&&!ulm_ie7)b.parentNode.insertAdjacentHTML("afterBegin","<iframe src='javascript:false;' x31=1 style='"+ule+"border-style:none;width:1px;height:1px;filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=0);' frameborder='0'></iframe>");if(!ulm_iemac||level>1||!dto.main_is_horizontal)bp.style.zIndex=level;bp.setAttribute("align","left");var x4="sub";if(level==1)x4="main";if(iname=dto[x4+"_expand_image"]){x14=dto[x4+"_expand_image_hover"];x15=new Array(dto[x4+"_expand_image_width"],dto[x4+"_expand_image_height"]);tewid="100%";if(ulm_ie&&!ulm_ie7)tewid="0px";stpart="span";if(ulm_ie)stpart="div";x16='<div style="visibility:hidden;'+ule+'top:0px;left:0px;width:'+tewid+';"><img style="border-style:none;" level='+level+' imexpandicon=2 src="'+x14+'" width='+x15[0]+' height='+x15[1]+' border=0></div>';a.firstChild.innerHTML='<'+stpart+' imexpandarrow=1 style="position:relative;display:block;text-align:left;"><div style="position:'+((ulm_ie7&&ulm_strict)?("relative"):("absolute"))+';width:100%;'+ulm_curs+' text-align:right;"><div style="position:relative;width:'+tewid+';height:0px;text-align:right;top:'+dto[x4+"_expand_image_offy"]+'px;left:'+dto[x4+"_expand_image_offx"]+'px;">'+x16+'<img style="border-style:none;" imexpandicon=1 level='+level+' src="'+iname+'" width='+x15[0]+' height='+x15[1]+' border=0></div></div></'+stpart+'>'+a.firstChild.innerHTML;}b.parentNode.className="imsubc";b.id="x1ub"+prefix+counter;if(!ulm_oldnav&&ulmpi)ulmpi(b.parentNode,dto,level);new imenus_create_menu(b.childNodes,prefix+counter+x43,dto,d_toid);}if(!sid&&!ulm_navigator&&!ulm_iemac&&(rssurl=a.getAttribute("rssfeed"))&&(c=window.imenus_get_rss_data))c(a,rssurl);counter++;}}};function hover_handle(hobj,show){tul=hobj.getElementsByTagName("UL")[0];try{if((ulm_ie&&!ulm_mac)&&show&&(plobj=tul.filters[0])&&tul.parentNode.currentStyle.visibility=="hidden"){if(x44)x44.stop();plobj.apply();plobj.play();x44=plobj;}}catch(e){}if(show&&tul){if(!hobj.className&&!ulm_iemac&&!ulm_mglobal.design_mode&&!ulm_oldnav)x39(tul);}hover_2handle(hobj,show,tul)};function hover_2handle(hobj,show,tul){if((tco=cm_obj[hobj.level])!=null){tco.className="";tco.firstChild.className="";}if(show){if(!tul)return;hobj.firstChild.className="ihover iactive";hobj.className="ishow";cm_obj[hobj.level]=hobj;}};function get_doc_dimensions(){db=uld.body;var w=0;var h=0;if(tval=window.innerHeight){h=tval;w=window.innerWidth;}else  if((e=uld.documentElement)&&(e=e.clientHeight)){h=e;if(!(w=e.clientWidth)&&db)w=db.clientWidth;}else  if(e=db.clientHeight){h=e;w=db.clientWidth;}return new Array(w,h);};function x39(obj){var c=obj.parentNode;var d=obj.offsetWidth;var pos=x27(c);var db=uld.body;var wh=get_doc_dimensions();if(wh[1]&&(s1h=pos[1]+obj.offsetHeight)>wh[1])obj.style.top=(wh[1]-s1h)+"px";else  obj.style.top="";if(wh[0]&&(s1h=pos[0]+d)>wh[0])c.style.left=-d+"px";};function x27(obj){var x=0;var y=0;do{x+=obj.offsetLeft;y+=obj.offsetTop;}while(obj=obj.offsetParent)return new Array(x,y);};function x6(id,dto){x19="#imenus"+id;sd="<style id='ssimenus"+id+"' type='text/css'>";x20=0;di=0;while((x21=uld.getElementById("ulitem"+id+x43+di))){for(i=0;i<(wfl=x21.getElementsByTagName("SPAN")).length;i++){if(wfl[i].getAttribute("imrollimage")){wfl[i].onclick=function(){window.open(this.parentNode.href,((tpt=this.parentNode.target)?tpt:"_self"))};var a="#ulaitem"+id+x43+di;if(!ulm_iemac){var b=a+".ihover .ulmroll ";sd+=a+" .ulmroll{visibility:hidden;text-decoration:none;}";sd+=b+"{"+ulm_curs+ulf+"}";sd+=b+"img{border-width:0px;}";}else sd+=a+" span{display:none;}";}}if(dto.main_is_horizontal){if(ulm_iemac){if(a=dto.mac_margin_fix)x20+=a;x21.style.display="inline-block";}else sd+="#ulitem"+id+x43+di+"{float:left;}";if(tgw=x21.style.width)x20+=parseInt(tgw);}else {x20=parseInt(uld.getElementById("imenus"+id).style.width);x21.style.width="100%";}di++;}var c=uld.getElementById("imenus"+id);c.style.width=x20+"px";if(ulm_ie)c.parentNode.style.width=x20+"px";sd+="#imcontainer1"+id+"{text-align:left;z-index:"+(899-id)+";position:"+(ulm_oldnav?("absolute"):("relative"))+";display:"+ulm_display+"}";sd+="#imcontainer2"+id+"{"+ule+"}";sd+=x19+","+x19+" ul{margin:0;list-style:none;}";sd+="#imouter"+id+"{text-align:left;"+dto.main_container_styles+"}";if(!(scse=dto.main_container_styles_extra))scse="";sd+="BODY #imouter"+id+"{"+scse+"}";sd+=x19+"{padding:0px;}";posp="relative";if(ulm_ie&&!ulm_mac)posp="absolute";sd+=x19+" ul{padding:0px;"+dto.subs_container_styles+"position:"+posp+";top:0px;left:0px;}";if(!(scse=dto.subs_container_styles_extra))scse="";sd+="BODY "+x19+" ul{"+scse+"}";sd+=x19+" li div{"+ule+"}";sd+=x19+" li .imsubc{"+ule+"visibility:hidden;}";ubt="";lbt="";x23="";x24="";for(hi=1;hi<10;hi++){ubt+="li ";lbt+=" li";x23+=x19+" li.ishow "+ubt+" .imsubc";x24+=x19+lbt+".ishow .imsubc";if(hi!=9){x23+=",";x24+=",";}}sd+=x23+"{visibility:hidden;}";sd+=x24+"{"+ulf+"}";if(!ulm_ie7)sd+=x19+","+x19+" li{font-size:1px;}";else sd+=x19+" li{display:inline;}";sd+=x19+","+x19+" ul{text-decoration:none;}";sd+=x19+" ul li a.ihover{"+dto.subs_item_hover_styles+"}";sd+=x19+" li a.ihover{"+dto.main_item_hover_styles+"}";sd+=x19+" li a.iactive{"+dto.main_item_active_styles+"}";sd+=x19+" ul li a.iactive{"+dto.subs_item_active_styles+"}";sd+=x19+" li a.iactive div img{"+ulf+"}";ulp="";ulmp="";if(ulm_ie&&!ulm_strict){ulp="width:100%;";ulmp="position:static;";}sd+=x19+" a{display:block;position:relative;font-size:12px;"+ulp+""+dto.main_item_styles+"}";if((ulm_ie||window.opera)&&!ulm_strict){sd+=x19+" a td{"+dto.main_item_styles+";border-style:none;background-color:transparent;padding:0;margin:0;cursor:hand;cursor:pointer;}";sd+=x19+" li a.ihover td{"+dto.main_item_hover_styles+"}";sd+=x19+" li a.iactive td{"+dto.main_item_active_styles+"}";}sd+=x19+" a img{border-width:0px;}";if(!(scse=dto.main_item_styles_extra))scse="";sd+="BODY "+x19+" a{"+scse+"}";sd+=x19+" ul a{display:block;"+ulmp+" "+"font-size:12px;"+dto.subs_item_styles+"}";if(!(scse=dto.subs_item_styles_extra))scse="";sd+="BODY "+x19+" ul a{"+scse+"}";sd+=x19+" li{"+ulm_curs+"}";sd+=x19+" .ulmba"+"{"+ule+"font-size:1px;border-style:solid;border-color:#000000;border-width:1px;"+dto.box_animation_styles+"}";uld.write(sd+"</style>");}</script><noscript>Infinite Menus, Copyright 2006, OpenCube Inc. All Rights Reserved.<a href="http://www.opencube.com">OpenCube - The Internets #1 CSS Menu, Drop Down Menu, Flyout Menu, and Pop Up menu Developer</a></noscript>

<!--  *********************************************** End Source Code ******************************************** -->

Kod: Markera allt

-Overall_Header.tpl-
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html dir="{S_CONTENT_DIRECTION}">
<head>
<meta http-equiv="Content-Type" content="text/html; charset={S_CONTENT_ENCODING}">
<meta http-equiv="Content-Style-Type" content="text/css">
{META}
{NAV_LINKS}
<title>{SITENAME} :: {PAGE_TITLE}</title>
<!-- link rel="stylesheet" href="templates/subSilver/{T_HEAD_STYLESHEET}" type="text/css" -->
<style type="text/css">
<!--
/*
  The original subSilver Theme for phpBB version 2+
  Created by subBlue design
  http://www.subBlue.com

  NOTE: These CSS definitions are stored within the main page body so that you can use the phpBB2
  theme administration centre. When you have finalised your style you could cut the final CSS code
  and place it in an external file, deleting this section to save bandwidth.
*/

/* General page style. The scroll bar colours only visible in IE5.5+ */
body { 
	background-color: {T_BODY_BGCOLOR};
	scrollbar-face-color: {T_TR_COLOR2};
	scrollbar-highlight-color: {T_TD_COLOR2};
	scrollbar-shadow-color: {T_TR_COLOR2};
	scrollbar-3dlight-color: {T_TR_COLOR3};
	scrollbar-arrow-color:  {T_BODY_LINK};
	scrollbar-track-color: {T_TR_COLOR1};
	scrollbar-darkshadow-color: {T_TH_COLOR1};
}

/* General font families for common tags */
font,th,td,p { font-family: {T_FONTFACE1} }
a:link,a:active,a:visited { color : {T_BODY_LINK}; }
a:hover		{ text-decoration: underline; color : {T_BODY_HLINK}; }
hr	{ height: 0px; border: solid {T_TR_COLOR3} 0px; border-top-width: 1px;}

/* This is the border line & background colour round the entire page */
.bodyline	{ background-color: {T_TD_COLOR2}; border: 1px {T_TH_COLOR1} solid; }

/* This is the outline round the main forum tables */
.forumline	{ background-color: {T_TD_COLOR2}; border: 2px {T_TH_COLOR2} solid; }

/* Main table cell colours and backgrounds */
td.row1	{ background-color: {T_TR_COLOR1}; }
td.row2	{ background-color: {T_TR_COLOR2}; }
td.row3	{ background-color: {T_TR_COLOR3}; }

/*
  This is for the table cell above the Topics, Post & Last posts on the index.php page
  By default this is the fading out gradiated silver background.
  However, you could replace this with a bitmap specific for each forum
*/
td.rowpic {
		background-color: {T_TD_COLOR2};
		background-image: url(templates/subSilver/images/{T_TH_CLASS3});
		background-repeat: repeat-y;
}

/* Header cells - the blue and silver gradient backgrounds */
th	{
	color: {T_FONTCOLOR3}; font-size: {T_FONTSIZE2}px; font-weight : bold; 
	background-color: {T_BODY_LINK}; height: 25px;
	background-image: url(templates/subSilver/images/{T_TH_CLASS2});
}

td.cat,td.catHead,td.catSides,td.catLeft,td.catRight,td.catBottom {
			background-image: url(templates/subSilver/images/{T_TH_CLASS1});
			background-color:{T_TR_COLOR3}; border: {T_TH_COLOR3}; border-style: solid; height: 28px;
}

/*
  Setting additional nice inner borders for the main table cells.
  The names indicate which sides the border will be on.
  Don't worry if you don't understand this, just ignore it :-)
*/
td.cat,td.catHead,td.catBottom {
	height: 29px;
	border-width: 0px 0px 0px 0px;
}
th.thHead,th.thSides,th.thTop,th.thLeft,th.thRight,th.thBottom,th.thCornerL,th.thCornerR {
	font-weight: bold; border: {T_TD_COLOR2}; border-style: solid; height: 28px;
}
td.row3Right,td.spaceRow {
	background-color: {T_TR_COLOR3}; border: {T_TH_COLOR3}; border-style: solid;
}

th.thHead,td.catHead { font-size: {T_FONTSIZE3}px; border-width: 1px 1px 0px 1px; }
th.thSides,td.catSides,td.spaceRow	 { border-width: 0px 1px 0px 1px; }
th.thRight,td.catRight,td.row3Right	 { border-width: 0px 1px 0px 0px; }
th.thLeft,td.catLeft	  { border-width: 0px 0px 0px 1px; }
th.thBottom,td.catBottom  { border-width: 0px 1px 1px 1px; }
th.thTop	 { border-width: 1px 0px 0px 0px; }
th.thCornerL { border-width: 1px 0px 0px 1px; }
th.thCornerR { border-width: 1px 1px 0px 0px; }

/* The largest text used in the index page title and toptic title etc. */
.maintitle	{
	font-weight: bold; font-size: 22px; font-family: "{T_FONTFACE2}",{T_FONTFACE1};
	text-decoration: none; line-height : 120%; color : {T_BODY_TEXT};
}

/* General text */
.gen { font-size : {T_FONTSIZE3}px; }
.genmed { font-size : {T_FONTSIZE2}px; }
.gensmall { font-size : {T_FONTSIZE1}px; }
.gen,.genmed,.gensmall { color : {T_BODY_TEXT}; }
a.gen,a.genmed,a.gensmall { color: {T_BODY_LINK}; text-decoration: none; }
a.gen:hover,a.genmed:hover,a.gensmall:hover	{ color: {T_BODY_HLINK}; text-decoration: underline; }

/* The register, login, search etc links at the top of the page */
.mainmenu		{ font-size : {T_FONTSIZE2}px; color : {T_BODY_TEXT} }
a.mainmenu		{ text-decoration: none; color : {T_BODY_LINK};  }
a.mainmenu:hover{ text-decoration: underline; color : {T_BODY_HLINK}; }

/* Forum category titles */
.cattitle		{ font-weight: bold; font-size: {T_FONTSIZE3}px ; letter-spacing: 1px; color : {T_BODY_LINK}}
a.cattitle		{ text-decoration: none; color : {T_BODY_LINK}; }
a.cattitle:hover{ text-decoration: underline; }

/* Forum title: Text and link to the forums used in: index.php */
.forumlink		{ font-weight: bold; font-size: {T_FONTSIZE3}px; color : {T_BODY_LINK}; }
a.forumlink 	{ text-decoration: none; color : {T_BODY_LINK}; }
a.forumlink:hover{ text-decoration: underline; color : {T_BODY_HLINK}; }

/* Used for the navigation text, (Page 1,2,3 etc) and the navigation bar when in a forum */
.nav			{ font-weight: bold; font-size: {T_FONTSIZE2}px; color : {T_BODY_TEXT};}
a.nav			{ text-decoration: none; color : {T_BODY_LINK}; }
a.nav:hover		{ text-decoration: underline; }

/* titles for the topics: could specify viewed link colour too */
.topictitle,h1,h2	{ font-weight: bold; font-size: {T_FONTSIZE2}px; color : {T_BODY_TEXT}; }
a.topictitle:link   { text-decoration: none; color : {T_BODY_LINK}; }
a.topictitle:visited { text-decoration: none; color : {T_BODY_VLINK}; }
a.topictitle:hover	{ text-decoration: underline; color : {T_BODY_HLINK}; }

/* Name of poster in viewmsg.php and viewtopic.php and other places */
.name			{ font-size : {T_FONTSIZE2}px; color : {T_BODY_TEXT};}

/* Location, number of posts, post date etc */
.postdetails		{ font-size : {T_FONTSIZE1}px; color : {T_BODY_TEXT}; }

/* The content of the posts (body of text) */
.postbody { font-size : {T_FONTSIZE3}px; line-height: 18px}
a.postlink:link	{ text-decoration: none; color : {T_BODY_LINK} }
a.postlink:visited { text-decoration: none; color : {T_BODY_VLINK}; }
a.postlink:hover { text-decoration: underline; color : {T_BODY_HLINK}}

/* Quote & Code blocks */
.code { 
	font-family: {T_FONTFACE3}; font-size: {T_FONTSIZE2}px; color: {T_FONTCOLOR2};
	background-color: {T_TD_COLOR1}; border: {T_TR_COLOR3}; border-style: solid;
	border-left-width: 1px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px
}

.quote {
	font-family: {T_FONTFACE1}; font-size: {T_FONTSIZE2}px; color: {T_FONTCOLOR1}; line-height: 125%;
	background-color: {T_TD_COLOR1}; border: {T_TR_COLOR3}; border-style: solid;
	border-left-width: 1px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px
}

/* Copyright and bottom info */
.copyright		{ font-size: {T_FONTSIZE1}px; font-family: {T_FONTFACE1}; color: {T_FONTCOLOR1}; letter-spacing: -1px;}
a.copyright		{ color: {T_FONTCOLOR1}; text-decoration: none;}
a.copyright:hover { color: {T_BODY_TEXT}; text-decoration: underline;}

/* Form elements */
input,textarea, select {
	color : {T_BODY_TEXT};
	font: normal {T_FONTSIZE2}px {T_FONTFACE1};
	border-color : {T_BODY_TEXT};
}

/* The text input fields background colour */
input.post, textarea.post, select {
	background-color : {T_TD_COLOR2};
}

input { text-indent : 2px; }

/* The buttons used for bbCode styling in message post */
input.button {
	background-color : {T_TR_COLOR1};
	color : {T_BODY_TEXT};
	font-size: {T_FONTSIZE2}px; font-family: {T_FONTFACE1};
}

/* The main submit button option */
input.mainoption {
	background-color : {T_TD_COLOR1};
	font-weight : bold;
}

/* None-bold submit button */
input.liteoption {
	background-color : {T_TD_COLOR1};
	font-weight : normal;
}

/* This is the line in the posting page which shows the rollover
  help line. This is actually a text box, but if set to be the same
  colour as the background no one will know ;)
*/
.helpline { background-color: {T_TR_COLOR2}; border-style: none; }

/* Import the fancy styles for IE only (NS4.x doesn't use the @import function) */
@import url("templates/subSilver/formIE.css"); 
-->
</style>
<!-- BEGIN switch_enable_pm_popup -->
<script language="Javascript" type="text/javascript">
<!--
	if ( {PRIVATE_MESSAGE_NEW_FLAG} )
	{
		window.open('{U_PRIVATEMSGS_POPUP}', '_phpbbprivmsg', 'HEIGHT=225,resizable=yes,WIDTH=400');;
	}
//-->
</script>
<!-- END switch_enable_pm_popup -->
</head>
<body bgcolor="{T_BODY_BGCOLOR}" text="{T_BODY_TEXT}" link="{T_BODY_LINK}" vlink="{T_BODY_VLINK}">

<a name="top"></a>

<table width="100%" cellspacing="0" cellpadding="10" border="0" align="center"> 
	<tr> 
		<td class="bodyline"><table width="100%" cellspacing="0" cellpadding="0" border="0">
			<tr> 
				<td><a href="{U_PORTAL}"><img src="templates/subSilver/images/logo_phpBB.gif" border="0" alt="{L_INDEX}" vspace="1" /></a></td>
				<td align="center" width="100%" valign="middle"><span class="maintitle"></span><br /><span class="gen"><br />&nbsp; </span> 
				<table cellspacing="0" cellpadding="2" border="0">
					<tr> 
						<td align="center" valign="top" nowrap="nowrap"><span class="mainmenu">&nbsp;<a href="{U_PORTAL}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_message.gif" width="12" height="13" border="0" alt="{L_HOME}" hspace="3" />{L_HOME}</a>&nbsp;&nbsp;<a href="{U_FAQ}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_faq.gif" width="12" height="13" border="0" alt="{L_FAQ}" hspace="3" />{L_FAQ}</a>&nbsp; &nbsp;<a href="{U_SEARCH}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_search.gif" width="12" height="13" border="0" alt="{L_SEARCH}" hspace="3" />{L_SEARCH}</a>&nbsp; &nbsp;<a href="{U_MEMBERLIST}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_members.gif" width="12" height="13" border="0" alt="{L_MEMBERLIST}" hspace="3" />{L_MEMBERLIST}</a>&nbsp; &nbsp;<a href="{U_GROUP_CP}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_groups.gif" width="12" height="13" border="0" alt="{L_USERGROUPS}" hspace="3" />{L_USERGROUPS}</a>&nbsp; 
						<!-- BEGIN switch_user_logged_out -->
					
&nbsp;<a href="{U_REGISTER}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_register.gif" width="12" height="13" border="0" alt="{L_REGISTER}" hspace="3" />{L_REGISTER}</a>&nbsp;
						<!-- END switch_user_logged_out -->
						</span></td>
					</tr>
					<tr>
						<td height="25" align="center" valign="top" nowrap="nowrap"><span class="mainmenu">&nbsp;<a href="{U_PROFILE}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_profile.gif" width="12" height="13" border="0" alt="{L_PROFILE}" hspace="3" />{L_PROFILE}</a>&nbsp; &nbsp;<a href="{U_PRIVATEMSGS}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_message.gif" width="12" height="13" border="0" alt="{PRIVATE_MESSAGE_INFO}" hspace="3" />{PRIVATE_MESSAGE_INFO}</a>&nbsp; &nbsp;<a href="{U_LOGIN_LOGOUT}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_login.gif" width="12" height="13" border="0" alt="{L_LOGIN_LOGOUT}" hspace="3" />{L_LOGIN_LOGOUT}</a>&nbsp;</span></td>
					</tr>
				</table></td>
			</tr>
		</table>

		<br />
caras
Extra aktiv medlem
Extra aktiv medlem
Inlägg: 142
Blev medlem: 2006-04-13 04:17
Svar: 0

Inlägg av caras »

istället för att lägga javascript koden i overall_header.tpl så lägg in en extern länk mellan <head> och </head>

<script language="JavaScript" src="sida.js" type="text/javascript"></script>

lägg dina js koder separat annars kommer dina koder slöa ner sidan.. alltså js koden sparar du som *.js

ser att du lagt upp din kodan ovan men det ser lite huller om buller ut..
Skriv svar

Vilka är online

Användare som besöker denna kategori: 2 och 0 gäster