Foros del Web » Creando para Internet » HTML »

problema con un javascript

Estas en el tema de problema con un javascript en el foro de HTML en Foros del Web. hola buenos os explico el problema por si alguno me puede aconsejar He montado un menu desplegable de un javascript. Lo e montado en un ...
  #1 (permalink)  
Antiguo 17/04/2002, 17:47
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
problema con un javascript

hola
buenos os explico el problema por si alguno me puede aconsejar
He montado un menu desplegable de un javascript. Lo e montado en un marco y kiero k al pulsar los vinculos del menu me cambie el marco de abajo

a ver si alguien me dice lo k le tengo k hacer al codigo
puesto lo k me hace es cambiarme el marco donde esta el menu
con el dreamweaver esto lo hago perfecto pero ahora en un javascript supongo k habra k cambiarle algo al codigo

saludos-totorroto
  #2 (permalink)  
Antiguo 17/04/2002, 20:10
 
Fecha de Ingreso: diciembre-2001
Ubicación: Madrid
Mensajes: 889
Antigüedad: 16 años
Puntos: 4
Re: problema con un javascript

Si es con javascript, sería algo como:
window.open('pagina.htm','nombre_del_marco')

Si es con un link normal y corriente, añadiendo al tag Target="nombre_del_marco"
<a href="pagina.htm" target="nombre_del_marco">Link a otra ventana</a>

Espero que sea eso lo que buscabas y sino,pon el código en el que lo quieres hacer, y nos ponemos con ello ;)

Saludos!
  #3 (permalink)  
Antiguo 17/04/2002, 20:26
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

muchas gracias voy a probar
mañana te cuento
saludos-totorroto
  #4 (permalink)  
Antiguo 18/04/2002, 12:07
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

nada no lo consigo
me cambia el mismo marco donde tengo el javascripts te pego el codigo:
<<script language="JavaScript" src="navcond.js">
</script>

<script language="JavaScript">

/*
Top Navigational Bar II (By Mike Hall @ Brainjar.com)
*/

var myNavBar1 = new NavBar(0);
var dhtmlMenu;

//define menu items (first parameter of NavBarMenu specifies main category width, second specifies sub category width in pixels)
//add more menus simply by adding more "blocks" of same code below
dhtmlMenu = new NavBarMenu(100, 0);
dhtmlMenu.addItem(new NavBarMenuItem("GAMES", "index.htm"));
dhtmlMenu.addItem(new NavBarMenuItem("PS2", "caducar.htm", "frame"));
dhtmlMenu.addItem(new NavBarMenuItem("PC", "caducar.htm"));
dhtmlMenu.addItem(new NavBarMenuItem("ROM", "caducar.htm"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 120);
dhtmlMenu.addItem(new NavBarMenuItem("APPS", ""));
dhtmlMenu.addItem(new NavBarMenuItem("DISEÑO", "caducar.htm"));
dhtmlMenu.addItem(new NavBarMenuItem("INTERNET", "ventanafull.htm"));
dhtmlMenu.addItem(new NavBarMenuItem("ANTIVIRUS", "mouse.htm"));
dhtmlMenu.addItem(new NavBarMenuItem("S.OPERATIVOS", "caducar.htm"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(110, 120);
dhtmlMenu.addItem(new NavBarMenuItem("PELICULAS", ""));
dhtmlMenu.addItem(new NavBarMenuItem("VCD", "http://www.lavariable.com"));
dhtmlMenu.addItem(new NavBarMenuItem("DIVX", "http://www.programacion.net"));
dhtmlMenu.addItem(new NavBarMenuItem("REPRODUCTORES", "http://www.abcdatos.com/"));
dhtmlMenu.addItem(new NavBarMenuItem("UTILIDADES", "http://www.cybercursos.net/"));
dhtmlMenu.addItem(new NavBarMenuItem("MANUALES", "caducar.htm"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 150);
dhtmlMenu.addItem(new NavBarMenuItem("ELECTRONICA", ""));
dhtmlMenu.addItem(new NavBarMenuItem("CSD", "http://www.yahoo.com"));
dhtmlMenu.addItem(new NavBarMenuItem("VIA", "http://www.altavista.com"));
dhtmlMenu.
  #5 (permalink)  
Antiguo 18/04/2002, 12:08
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

dhtmlMenu.addItem(new NavBarMenuItem("CONSOLAS", "http://www.infoseek.com"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 150);
dhtmlMenu.addItem(new NavBarMenuItem("FTP", ""));
dhtmlMenu.addItem(new NavBarMenuItem("LISTAS FTPZ", "http://www.forosdelweb.com"));
dhtmlMenu.addItem(new NavBarMenuItem("UTILIDADES", "http://www.desarrolloweb.com"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 150);
dhtmlMenu.addItem(new NavBarMenuItem("FOROS", ""));
dhtmlMenu.addItem(new NavBarMenuItem("DECODIFICACION", "http://www.forosdelweb.com"));
dhtmlMenu.addItem(new NavBarMenuItem("GAMES", "http://www.forosdelweb.com"));
dhtmlMenu.addItem(new NavBarMenuItem("FTPZ", "http://www.forosdelweb.com"));
myNavBar1.addMenu(dhtmlMenu);

//set menu colors
myNavBar1.setColors("#ffffff","#fff fff","#000000","#ffffff", "#6B6B6B","#000000","#C0C 0C0","#ffffff","#8A0000")
myNavBar1.setFonts("Arial","plain&q uot;,"bold","11px","Arial ","plain","bold","11 px");

//uncomment below line to center the menu (valid values are "left", "center", and "right"
//myNavBar1.setAlign("center")

var fullWidth;

function init() {

// Get width of window, need to account for scrollbar width in Netscape.

fullWidth = getWindowWidth()
- (isMinNS4 && getWindowHeight() < getPageHeight() ? 16 : 0);

myNavBar1.resize(fullWidth);
myNavBar1.create();
myNavBar1.setzIndex(2);
}/script>
  #6 (permalink)  
Antiguo 18/04/2002, 12:10
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

tambien lleva navcond.js

k si ves k hace falta lo pego

darte muchisimas gracias por todo
con gente asi es un gusto aprender cosas
saludos-totorroto
  #7 (permalink)  
Antiguo 18/04/2002, 12:16
 
Fecha de Ingreso: julio-2001
Ubicación: Internet
Mensajes: 1.690
Antigüedad: 16 años, 4 meses
Puntos: 1
Re: problema con un javascript

Hola!,

Pera El navcond.js, Es NEcesario Ya Que Alli Se Encuentra La Funcion.

Fuera De Esto Podrias Decirnos Cual Es el Nombre Del Marco Donde Quieres Aparesca¿?, El Nombre Se Define Con El Atributo Name, Asi:

<FRAME NAME="algo" SRC="...

<SCRIPT LANGUAGE="javascript" SRC="http://www.galeon.com/jlmnetwork/firma.js"></SCRIPT>
  #8 (permalink)  
Antiguo 18/04/2002, 12:30
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

var isMinNS4=(navigator.appName.indexOf(&quot;Netscape &quot;)&gt;=0&amp;&amp;parseFloat(navigator.appVer sion)&gt;=4)?1:0;var isMinIE4=(document.all)?1:0;var isMinIE5=(isMinIE4&amp;&amp;navigator.appVersion.i ndexOf(&quot;5.&quot;)&gt;=0)?1:0;function hideLayer(layer){if(isMinNS4)layer.visibility=&quo t;hide&quot;;if(isMinIE4)layer.style.visibility=&q uot;hidden&quot;;}function showLayer(layer){if(isMinNS4)layer.visibility=&quo t;show&quot;;if(isMinIE4)layer.style.visibility=&q uot;visible&quot;;}function inheritLayer(layer){if(isMinNS4)layer.visibility=& quot;inherit&quot;;if(isMinIE4)layer.style.visibil ity=&quot;inherit&quot;;}function getVisibility(layer){if(isMinNS4){if(layer.visibil ity==&quot;show&quot;)return &quot;visible&quot;;if(layer.visibility==&quot;hid e&quot;)return &quot;hidden&quot;;return layer.visibility;}if(isMinIE4)return layer.style.visibility;return &quot;&quot;;}function moveLayerTo(layer,x,y){if(isMinNS4)layer.moveTo(x, y);if(isMinIE4){layer.style.left=x;layer.style.top =y;}}function moveLayerBy(layer,dx,dy){if(isMinNS4)layer.moveBy( dx,dy);if(isMinIE4){layer.style.pixelLeft+=dx;laye r.style.pixelTop+=dy;}}function getLeft(layer){if(isMinNS4)return layer.left;if(isMinIE4)return layer.style.pixelLeft;return-1;}function getTop(layer){if(isMinNS4)return layer.top;if(isMinIE4)return layer.style.pixelTop;return-1;}function getRight(layer){if(isMinNS4)return layer.left+getWidth(layer);if(isMinIE4)return layer.style.pixelLeft+getWidth(layer);return-1;}function getBottom(layer){if(isMinNS4)return layer.top+getHeight(layer);if(isMinIE4)return layer.style.pixelTop+getHeight(layer);return-1;}function getPageLeft(layer){var x;if(isMinNS4)return layer.pageX;if(isMinIE4){x=0;while(layer.offsetPar ent!=null){x+=layer.offsetLeft;layer=layer.offsetP arent;}x+=layer.offsetLeft;return x;}return-1;}function getPageTop(layer){var y;if(isMinNS4)return layer.pageY;if(isMinIE4){y=0;while(layer.offsetPar ent!=null){y+=layer.offsetTop;layer=layer.offsetPa rent;}y+=layer.offsetTop;return y;}return-1;}function getWidth(layer){if(isMinNS4){if(layer.document.wid th)return layer.document.width;else return layer.clip.right-layer.clip.left;}if(isMinIE4){if(layer.style.pixel Width)return layer.style.pixelWidth;else return layer.clientWidth;}return-1;}function getHeight(layer){if(isMinNS4){if(layer.document.he ight)return layer.document.height;else return layer.clip.bottom-layer.clip.top;}if(isMinIE4){if(layer.style.pixelH eight)return layer.style.pixelHeight;else return layer.clientHeight;}return-1;}function getzIndex(layer){if(isMinNS4)return layer.zIndex;if(isMinIE4)return layer.style.zIndex;return-1;}function setzIndex(layer,z){if(isMinNS4)layer.zIndex=z;if(i sMinIE4)layer.style.zIndex=z;}function clipLayer(layer,clipleft,cliptop,clipright,clipbot tom){if(isMinNS4){layer.clip.left=clipleft;layer.c lip.top=cliptop;layer.clip.right=clipright;layer.c lip.bottom=clipbottom;}if(isMinIE4)layer.style.cli p='rect('+cliptop+' '+clipright+' '+clipbottom+' '+clipleft+')';}function getClipLeft(layer){if(isMinNS4)return layer.clip.left;if(isMinIE4){var str=layer.style.clip;if(!str)return 0;var clip=getIEClipValues(layer.style.clip);return(clip[3]);}return-1;}function getClipTop(layer){if(isMinNS4)return layer.clip.top;if(isMinIE4){var str=layer.style.clip;if(!str)return 0;var clip=getIEClipValues(layer.style.clip);return clip[0];}return-1;}function getClipRight(layer){if(isMinNS4)return layer.clip.right;if(isMinIE4){var str=layer.style.clip;if(!str)return layer.style.pixelWidth;var clip=getIEClipValues(layer.style.clip);return clip[1];}return-1;}function getClipBottom(layer){if(isMinNS4)return layer.clip.bottom;if(isMinIE4){var str=layer.style.clip;if(!str)return layer.style.pixelHeight;var clip=getIEClipValues(layer.style.clip);return clip[2];}return-1;}function getClipWidth(layer){if(isMinNS4)return layer.clip.width;if(isMinIE4){var str=layer.style.clip;if(!str)return layer.style.pixelWidth;var clip=getIEClipValues(layer.style.clip);return clip[1]-clip[3];}return-1;}function getClipHeight(layer){if(isMinNS4)return layer.clip.height;if(isMinIE4){var str=layer.style.clip;if(!str)return layer.style.pixelHeight;var clip=getIEClipValues(layer.style.clip);return clip[2]-clip[0];}return-1;}function getIEClipValues(str){var clip=new Array();var i;i=str.indexOf(&quot;(&quot;);clip[0]=parseInt(str.substring(i+1,str.length),10);i=str. indexOf(&quot; &quot;,i+1);clip[1]=parseInt(str.substring(i+1,str.length),10);i=str. indexOf(&quot; &quot;,i+1);clip[2]=parseInt(str.substring(i+1,str.length),10);i=str. indexOf(&quot; &quot;,i+1);clip[3]=parseInt(str.substring(i+1,str.length),10);return clip;}function scrollLayerTo(layer,x,y,bound){var dx=getClipLeft(layer)-x;var dy=getClipTop(layer)-y;scrollLayerBy(layer,-dx,-dy,bound);}function scrollLayerBy(layer,dx,dy,bound){var cl=getClipLeft(layer);var ct=getClipTop(layer);var cr=getClipRight(layer);var cb=getClipBottom(layer);if(bound){if(cl+dx&lt;0)dx =-cl;else if(cr+dx&gt;getWidth(layer))dx=getWidth(layer)-cr;if(ct+dy&lt;0)dy=-ct;else if(cb+dy&gt;getHeight(layer))dy=getHeight(layer)-cb;}clipLayer(layer,cl+dx,ct+dy,cr+dx,cb+dy);moveL ayerBy(layer,-dx,-dy);}function setBgColor(layer,color){if(isMinNS4)layer.bgColor= color;if(isMinIE4)layer.style.backgroundColor=colo r;}function setBgImage(layer,src){if(isMinNS4)layer.background .src=src;if(isMinIE4)layer.style.backgroundImage=& quot;url(&quot;+src+&quot;)&quot;;}function getLayer(name){if(isMinNS4)return findLayer(name,document);if(isMinIE4)return eval('document.all.'+name);return null;}function findLayer(name,doc){var i,layer;for(i=0;i&lt;doc.layers.length;i++){layer= doc.layers[I];if(layer.name==name)return layer;if(layer.document.layers.length&gt;0)if((lay er=findLayer(name,layer.document))!=null)return layer;}return null;}function getImage(name){if(isMinNS4){return findImage(name,document);}if(isMinIE4)return eval('document.all.'+name);return null;}function findImage(name,doc){var i,img;for(i=0;i&lt;doc.images.length;i++)if(doc.im ages[i].name==name)return doc.images[i];for(i=0;i&lt;doc.layers.length;i++)if((img=findIm age(name,doc.layers[i].document))!=null){img.container=doc.layers;return img;}return null;}function getImagePageLeft(img){var x,obj;if(isMinNS4){if(img.container!=null)return img.container.pageX+img.x;else return img.x;}if(isMinIE4){x=0;obj=img;while(obj.offsetPa rent!=null){x+=obj.offsetLeft;obj=obj.offsetParent ;}x+=obj.offsetLeft;return x;}return-1;}function getImagePageTop(img){var y,obj;if(isMinNS4){if(img.container!=null)return img.container.pageY+img.y;else return img.y;}if(isMinIE4){y=0;obj=img;while(obj.offsetPa rent!=null){y+=obj.offsetTop;obj=obj.offsetParent; }y+=obj.offsetTop;return y;}return-1;}function getWindowWidth(){if(isMinNS4)return window.innerWidth;if(isMinIE4)return document.body.clientWidth;return-1;}function getWindowHeight(){if(isMinNS4)return window.innerHeight;if(isMinIE4)return document.body.clientHeight;return-1;}function getPageWidth(){if(isMinNS4)return document.width;if(isMinIE4)return document.body.scrollWidth;return-1;}function getPageHeight(){if(isMinNS4)return document.height;if(isMinIE4)return document.body.scrollHeight;return-1;}function getPageScrollX(){if(isMinNS4)return window.pageXOffset;if(isMinIE4)return document.body.scrollLeft;return-1;}function getPageScrollY(){if(isMinNS4)return window.pageYOffset;if(isMinIE4)return document.body.scrollTop;return-1;}var isMinIE5_5=(isMinIE5&amp;&amp;navigator.appVersion .indexOf(&quot;5.5&quot;)&gt;=0)?1:0;var navBars=new Array();function NavBarMenuItem(text,link){this.text=text;this.link =link;}function NavBarMenu(hdrWidth,menuWidth){this.hdrWidth=hdrWi dth;this.width=menuWidth;this.height=0;this.items= new Array();this.addItem=navBarMenuAddItem;}function navBarMenuAddItem(item){this.items[this.items.length]=item;}function NavBar(width){this.x=0;this.y=0;this.width=width;t his.height=0;this.align=&quot;left&quot;;this.minW idth=0;this.inverted=false;this.menus=new Array();this.created=false;this.border=2;this.padd ing=4;this.separator=1;this.borderColor=&quot;#000 000&quot;;this.hdrFgColor=&quot;#000000&quot;;this .hdrBgColor=&quot;#999999&quot;;this.hdrHiFgColor= &quot;#ffffff&quot;;this.hdrHiBgColor=&quot;#66666 6&quot;;this.itmFgColor=&quot;#000000&quot;;this.i tmBgColor=&quot;#cccccc&quot;;this.itmHiFgColor=&q uot;#ffffff&quot;;this.itmHiBgColor=&quot;#000080& quot;;this.hdrFontFamily=&quot;Arial,Helvetica,san s-serif&quot;;this.hdrFontStyle=&quot;plain&quot;;th is.hdrFontWeight=&quot;bold&quot;;this.hdrFontSize =&quot;10pt&quot;;this.itmFontFamily=&quot;MS Sans Serif,Arial,Helvetica,sans-serif&quot;;this.itmFontStyle=&quot;plain&quot;;th is.itmFontWeight=&quot;bold&quot;;this.itmFontSize =&quot;8pt&quot;;this.setSizes=navBarSetSizes;this .setColors=navBarSetColors;this.setFonts=navBarSet Fonts;this.addMenu=navBarAddMenu;this.create=navBa rCreate;this.hide=navBarHide;this.show=navBarShow; this.moveTo=navBarMoveTo;this.moveBy=navBarMoveBy; this.getzIndex=navBarGetzIndex;this.setzIndex=navB arSetzIndex;this.getWidth=navBarGetWidth;this.getM inWidth=navBarGetMinWidth;this.getAlign=navBarGetA lign;this.setAlign=navBarSetAlign;this.resize=navB arResize;this.invert=navBarInvert;this.isInverted= navBarIsInverted;this.index=navBars.length;navBars[this.index]=this;}function navBarSetSizes(border,padding,separator){if(!this. created){this.border=border;this.padding=padding;t his.separator=separator;}}function navBarSetColors(bdColor,hdrFgColor,hdrBgColor,hdrH iFgColor,hdrHiBgColor,itmFgColor,itmBgColor,itmHiF gColor,itmHiBgColor){if(!this.created){this.border Color=bdColor;this.hdrFgColor=hdrFgColor;this.hdrB gColor=hdrBgColor;this.hdrHiFgColor=hdrHiFgColor;t his.hdrHiBgColor=hdrHiBgColor;this.itmFgColor=itmF gColor;this.itmBgColor=itmBgColor;this.itmHiFgColo r=itmHiFgColor;this.itmHiBgColor=itmHiBgColor;}}fu nction navBarSetFonts(hdrFamily,hdrStyle,hdrWeight,hdrSiz e,itmFamily,itmStyle,itmWeight,itmSize){if(!this.c reated){this.hdrFontFamily=hdrFamily;this.hdrFontS tyle=hdrStyle;this.hdrFontWeight=hdrWeight;this.hd rFontSize=hdrSize;this.itmFontFamily=itmFamily;thi s.itmFontStyle=itmStyle;this.itmFontWeight=itmWeig ht;this.itmFontSize=itmSize;}}function navBarAddMenu(menu){if(!this.created)this.menus[this.menus.length]=menu;}function navBarCreate(){var str;var i,j;var norm,high,end;var width,height;var x,y;var scrX,scrY;if(this.created||(!isMinNS4&amp;&amp;!is MinIE4))return;str=&quot;&quot;;if(isMinIE4&amp;&a mp;!isMinIE5){scrX=getPageScrollX();scrY=getPageSc rollY();window.scrollTo(getPageWidth(),getPageHeig ht());}if(isMinNS4)str+='&lt;layer name=&quot;navBar'+this.index+'_filler&quot;&gt;&l t;/layer&gt;\n&lt;layer name=&quot;navBar'+this.index+'_hdrsBase&quot;&gt; \n';if(isMinIE4)str+='&lt;div
  #9 (permalink)  
Antiguo 18/04/2002, 12:32
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

id=&quot;navBar'+this.index+'_filler&quot; style=&quot;position:absolute;&quot;&gt;&lt;/div&gt;\n&lt;div id=&quot;navBar'+this.index+'_hdrsBase&quot; style=&quot;position:absolute;&quot;&gt;\n';for(i= 0;i&lt;this.menus.length;i++){norm='&lt;table border=0 cellpadding='+this.padding+' cellspacing=0'+(this.menus[I].hdrWidth&gt;0?' width='+this.menus[i].hdrWidth:'')+((isMinIE4&amp;&amp;!isMinIE5)?' id=&quot;navBar'+this.index+'_tbl'+i+'&quot;':'')+ '&gt;&lt;tr&gt;&lt;td'+(this.menus[i].hdrWidth==0?' nowrap=1'+this.menus[i].hdrWidth:'')+'&gt;&lt;span style=&quot;color:'+this.hdrFgColor+';font-family:'+this.hdrFontFamily+';font-size:'+this.hdrFontSize+';font-style:'+this.hdrFontStyle+';font-weight:'+this.hdrFontWeight+';&quot;&gt;';high='&l t;table border=0 cellpadding='+this.padding+' cellspacing=0'+(this.menus[i].hdrWidth&gt;0?' width='+this.menus[i].hdrWidth:'')+'&gt;&lt;tr&gt;&lt;td'+(this.menus[i].hdrWidth==0?' nowrap=1'+this.menus[i].hdrWidth:'')+'&gt;&lt;span style=&quot;color:'+this.hdrHiFgColor+';font-family:'+this.hdrFontFamily+';font-size:'+this.hdrFontSize+';font-style:'+this.hdrFontStyle+';font-weight:'+this.hdrFontWeight+';&quot;&gt;';end='&lt ;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;';if(isMinNS4)str+='&lt;layer name=&quot;navBar'+this.index+'_head'+i+'&quot;&gt ;'+norm+this.menus[i].items[0].text+end+'&lt;/layer&gt;\n&lt;layer name=&quot;navBar'+this.index+'_headHigh'+i+'&quot ;&gt;'+high+this.menus[i].items[0].text+end+'&lt;/layer&gt;\n&lt;layer name=&quot;navBar'+this.index+'_headDummy'+i+'&quo t;&gt;&lt;/layer&gt;\n';if(isMinIE4){str+='&lt;div id=&quot;navBar'+this.index+'_head'+i+'&quot; style=&quot;position:absolute;&quot;&gt;'+norm+thi s.menus[i].items[0].text+end+'&lt;/div&gt;\n&lt;div id=&quot;navBar'+this.index+'_headHigh'+i+'&quot; style=&quot;position:absolute;&quot;&gt;'+high+thi s.menus[i].items[0].text+end+'&lt;/div&gt;\n&lt;div id=&quot;navBar'+this.index+'_headDummy'+i+'&quot; style=&quot;position:absolute;&quot;&gt;';if(isMin IE5_5)str+='&lt;table cellspacing=0 width=&quot;100%&quot; height=&quot;100%&quot;&gt;&lt;tr&gt;&lt;td&gt;&am p;nbsp;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;';str+='&lt;/div&gt;\n';}}if(isMinNS4){str+='&lt;/layer&gt;\n';this.baseLayer=new Layer(this.width);this.baseLayer.document.open();t his.baseLayer.document.write(str);this.baseLayer.d ocument.close();}if(isMinIE4){str+='&lt;/div&gt;\n';str='&lt;div id=&quot;navBar'+this.index+'&quot; style=&quot;position:absolute;left:0px;top:0px;&qu ot;&gt;\n'+str+'&lt;/div&gt;\n';document.body.insertAdjacentHTML(&quot; beforeEnd&quot;,str);this.baseLayer=getLayer(&quot ;navBar&quot;+this.index);}width=0;height=0;for(i= 0;i&lt;this.menus.length;i++){this.menus[i].hdrNormLayer=getLayer('navBar'+this.index+'_head' +i);this.menus[i].hdrHighLayer=getLayer('navBar'+this.index+'_headH igh'+i);this.menus[i].hdrDmmyLayer=getLayer('navBar'+this.index+'_headD ummy'+i);height=Math.max(height,getHeight(this.men us[i].hdrNormLayer));this.height=height+2*this.border;i f(isMinIE4&amp;&amp;!isMinIE5){width=this.menus[i].hdrWidth;if(width==0)width=eval('document.all.nav Bar'+this.index+'_tbl'+i+'.clientWidth');navBarIER esizeLayer(this.menus[i].hdrNormLayer,width,height);navBarIEResizeLayer(th is.menus[i].hdrHighLayer,width,height);navBarIEResizeLayer(th is.menus[i].hdrDmmyLayer,width,height);}}x=this.border;y=this .border;for(i=0;i&lt;this.menus.length;i++){width= Math.max(this.menus[i].hdrWidth,getWidth(this.menus[i].hdrNormLayer));if(this.menus[i].width==0)this.menus[i].width=width+2*this.border;moveLayerTo(this.menus[i].hdrNormLayer,x,y);setBgColor(this.menus[i].hdrNormLayer,this.hdrBgColor);clipLayer(this.menu s[i].hdrNormLayer,0,0,width,height);inheritLayer(this. menus[i].hdrNormLayer);moveLayerTo(this.menus[i].hdrHighLayer,x,y);setBgColor(this.menus[i].hdrHighLayer,this.hdrHiBgColor);clipLayer(this.me nus[i].hdrHighLayer,0,0,width,height);hideLayer(this.men us[i].hdrHighLayer);moveLayerTo(this.menus[i].hdrDmmyLayer,x,y);if(isMinIE4)navBarIEResizeLayer (this.menus[i].hdrDmmyLayer,width,height);clipLayer(this.menus[i].hdrDmmyLayer,0,0,width,height);inheritLayer(this. menus[i].hdrDmmyLayer);this.menus[i].hdrDmmyLayer.highLayer=this.menus[i].hdrHighLayer;this.menus[i].hdrLeft=x;x+=width+this.border;this.menus[i].hdrRight=x;}this.minWidth=x;this.width=Math.max(t his.minWidth,this.width);moveLayerTo(this.baseLaye r,this.x,this.y);setBgColor(this.baseLayer,this.bo rderColor);if(isMinIE4)navBarIEResizeLayer(this.ba seLayer,this.width,this.height);clipLayer(this.bas eLayer,0,0,this.width,this.height);this.fillerLaye r=getLayer('navBar'+this.index+'_filler');moveLaye rTo(this.fillerLayer,this.border,this.border);setB gColor(this.fillerLayer,this.hdrBgColor);width=thi s.width-2*this.border;height=this.height-2*this.border;if(isMinIE4)navBarIEResizeLayer(this .fillerLayer,width,height);clipLayer(this.fillerLa yer,0,0,width,height);inheritLayer(this.fillerLaye r);this.hdrsBaseLayer=getLayer('navBar'+this.index +'_hdrsBase');if(this.align==&quot;left&quot;)this .hdrsOffsetX=0;else if(this.align==&quot;center&quot;)this.hdrsOffsetX =Math.round((this.width-this.minWidth)/2);else if(this.align==&quot;right&quot;)this.hdrsOffsetX= this.width-this.minWidth;else this.hdrsOffsetX=Math.min(parseInt(this.align,10), this.width-this.minWidth);moveLayerTo(this.hdrsBaseLayer,this .hdrsOffsetX,0);setBgColor(this.hdrsBaseLayer,this .borderColor);if(isMinIE4)navBarIEResizeLayer(this .hdrsBaseLayer,this.minWidth,this.height);clipLaye r(this.hdrsBaseLayer,0,0,this.minWidth,this.height );inheritLayer(this.hdrsBaseLayer);for(i=0;i&lt;th is.menus.length;i++){this.menus[i].hdrDmmyLayer.index=this.index;this.menus[i].hdrDmmyLayer.offsetX=this.menus[i].hdrLeft-this.border;if(this.menus[i].hdrDmmyLayer.offsetX+this.menus[i].width&gt;this.width)this.menus[i].hdrDmmyLayer.offsetX=this.menus[i].hdrRight-this.menus[i].width;this.menus[i].hdrDmmyLayer.offsetY=this.height-this.border;this.menus[i].hdrDmmyLayer.onmouseover=navBarHeaderOn;this.menu s[i].hdrDmmyLayer.onmouseout=navBarHeaderOff;if(isMinN S4){this.menus[i].hdrDmmyLayer.document.highLayer=this.menus[i].hdrHighLayer;this.menus[i].hdrDmmyLayer.document.link=this.menus[i].items[0].link;this.menus[i].hdrDmmyLayer.document.captureEvents(Event.MOUSEUP );this.menus[i].hdrDmmyLayer.document.onmouseup=navBarItemClick;} if(isMinIE4){this.menus[i].hdrDmmyLayer.highLayer=this.menus[i].hdrHighLayer;this.menus[i].hdrDmmyLayer.link=this.menus[i].items[0].link;this.menus[i].hdrDmmyLayer.onclick=navBarItemClick;}}norm='&lt; table border=0 cellpadding='+this.padding+' cellspacing=0 width=&quot;100%&quot;&gt;&lt;tr&gt;&lt;td&gt;&lt; span style=&quot;color:'+this.itmFgColor+';font-family:'+this.itmFontFamily+';font-size:'+this.itmFontSize+';font-style:'+this.itmFontStyle+';font-weight:'+this.itmFontWeight+';&quot;&gt;';high='&l t;table border=0 cellpadding='+this.padding+' cellspacing=0 width=&quot;100%&quot;&gt;&lt;tr&gt;&lt;td&gt;&lt; span style=&quot;color:'+this.itmHiFgColor+';font-family:'+this.itmFontFamily+';font-size:'+this.itmFontSize+';font-style:'+this.itmFontStyle+';font-weight:'+this.itmFontWeight+';&quot;&gt;';end='&lt ;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;';for(i=0;i&lt;this.menus.length;i++){wid th=this.menus[i].width-2*this.border;str=&quot;&quot;;for(j=1;j&lt;this.m enus[i].items.length;j++){if(isMinNS4)str+='&lt;layer name=&quot;navBar'+this.index+'_menu'+i+'_norm'+j+ '&quot; width='+width+'&gt;'+norm+this.menus[i].items[j].text+end+'&lt;/layer&gt;\n&lt;layer name=&quot;navBar'+this.index+'_menu'+i+'_high'+j+ '&quot; width='+width+'&gt;'+high+this.menus[i].items[j].text+end+'&lt;/layer&gt;\n&lt;layer name=&quot;navBar'+this.index+'_menu'+i+'_dmmy'+j+ '&quot; width='+width+'&gt;&lt;/layer&gt;\n';if(isMinIE4){str+='&lt;div id=&quot;navBar'+this.index+'_menu'+i+'_norm'+j+'& quot; style=&quot;position:absolute;width:'+width+'px;&q uot;&gt;'+norm+this.menus[i].items[j].text+end+'&lt;/div&gt;\n&lt;div id=&quot;navBar'+this.index+'_menu'+i+'_high'+j+'& quot; style=&quot;position:absolute;width:'+width+'px;&q uot;&gt;'+high+this.menus[i].items[j].text+end+'&lt;/div&gt;\n&lt;div id=&quot;navBar'+this.index+'_menu'+i+'_dmmy'+j+'& quot; style=&quot;position:absolute;width:'+width+'px;&q uot;&gt;';if(isMinIE5_5)str+='&lt;table cellspacing=0 width=&quot;100%&quot; height=&quot;100%&quot;&gt;&lt;tr&gt;&lt;td&gt;&am p;nbsp;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;';str+='&lt;/div&gt;\n';}}if(isMinNS4){this.menus[i].baseLayer=new Layer(this.menus[i].width);this.menus[i].baseLayer.document.open();this.menus[i].baseLayer.document.write(str);this.menus[i].baseLayer.document.close();}if(isMinIE4){str='&lt ;div id=&quot;navBar'+this.index+'_menu'+i+'&quot; style=&quot;position:absolute;left:0px; top:0px;width:'+this.menus[i].width+'px;visibility:hidden;&quot;&gt;\n'+str+'&l t;/div&gt;\n';document.body.insertAdjacentHTML(&quot; beforeEnd&quot;,str);this.menus[i].baseLayer=getLayer(&quot;navBar&quot;+this.index+ &quot;_menu&quot;+i);}}if(isMinIE4&amp;&amp;!isMin IE5)window.scrollTo(x,y);for(i=0;i&lt;this.menus.l ength;i++){moveLayerTo(this.menus[i].baseLayer,this.menus[i].hdrDmmyLayer.offsetX,this.menus[i].hdrDmmyLayer.offsetY);setBgColor(this.menus[i].baseLayer,this.borderColor);if(this.menus[i].items.length&gt;1){this.menus[i].hdrDmmyLayer.menuLayer=this.menus[i].baseLayer;if(isMinNS4)this.menus[i].hdrDmmyLayer.document.menuLayer=this.menus[i].baseLayer;}else{this.menus[i].hdrDmmyLayer.menuLayer=null;if(isMinNS4)this.menu s[i].hdrDmmyLayer.document.menuLayer=this.menus[i].baseLayer;}x=this.border;y=this.border;width=this .menus[i].width-2*this.border;for(j=1;j&lt;this.menus[i].items.length;j++){this.menus[i].items[j].normLayer=getLayer('navBar'+this.index+'_menu'+i+ '_norm'+j);this.menus[i].items[j].highLayer=getLayer('navBar'+this.index+'_menu'+i+ '_high'+j);this.menus[i].items[j].dmmyLayer=getLayer('navBar'+this.index+'_menu'+i+ '_dmmy'+j);height=getHeight(this.menus[i].items[j].normLayer);moveLayerTo(this.menus[i].items[j].normLayer,x,y);setBgColor(this.menus[i].items[j].normLayer,this.itmBgColor);clipLayer(this.menus[i].items[j].normLayer,0,0,width,height);inheritLayer(this.men us[i].items[j].normLayer);moveLayerTo(this.menus[i].items[j].highLayer,x,y);setBgColor(this.menus[i].items[j].highLayer,this.itmHiBgColor);clipLayer(this.menus[i].items[j].highLayer,0,0,width,height);hideLayer(this.menus[i].items[j].highLayer);moveLayerTo(this.menus[i].items[j].dmmyLayer,x,y);if(isMinIE4)navBarIEResizeLayer(th is.menus[i].items[j].dmmyLayer,width,height);clipLayer(this.menus[i].items[j].dmmyLayer,0,0,width,height);inheritLayer(this.men us[i].items[j].dmmyLayer);this.menus[i].items[j].dmmyLayer.highLayer=this.menus[i].items[j].highLayer;this.menus[i].items[j].dmmyLayer.onmouseover=navBarItemOn;this.menus[i].items[j].dmmyLayer.onmouseout=navBarItemOff;if(isMinNS4){t his.menus[i].items[j].dmmyLayer.document.highLayer=this.menus[i].items[j].highLayer;this.menus[i].items[j].dmmyLayer.document.parentHighLayer=this.menus[i].hdrHighLayer;this.menus[i].items[j].dmmyLayer.document.menuLayer=this.menus[i].baseLayer;this.menus[i].items[j].dmmyLayer.document.link=this.menus[i].items[j].link;this.menus[i].items[j].dmmyLayer.document.captureEvents(Event.MOUSEUP);t his.menus[i].items[j].dmmyLayer.document.onmouseup=navBarItemClick;}if( isMinIE4){this.menus[i].items[j].dmmyLayer.highLayer=this.menus[i].items[j].highLayer;this.menus[i].items[j].dmmyLayer.parentHighLayer=this.menus[i].hdrHighLayer;this.menus[i].items[j].dmmyLayer.menuLayer=this.menus[i].baseLayer;this.menus[i].items[j].dmmyLayer.link=this.menus[i].items[j].link;this.menus[i].items[j].dmmyLayer.onclick=navBarItemClick;}y+=height+this .separator;}width=this.menus[i].width;height=y-this.separator+this.border;this.menus[i].baseLayer.width=this.menus[i].width;this.menus[i].baseLayer.height=height;if(isMinIE4)navBarIEResiz eLayer(this.menus[i].baseLayer,width,height);clipLayer(this.menus[i].baseLayer,0,0,width,height);this.menus[i].baseLayer.parentHighLayer=this.menus[i].hdrHighLayer;this.menus[i].baseLayer.onmouseout=navBarMenuOff;}this.created= true;this.resize(this.width);showLayer(this.baseLa yer);}function navBarHide(){if(this.created)hideLayer(this.baseLa yer);}function navBarShow(){if(this.created)showLayer(this.baseLa yer);}function navBarMoveTo(x,y){this.x=x;this.y=y;if(this.create d)moveLayerTo(this.baseLayer,this.x,this.y);}funct ion navBarMoveBy(dx,dy){this.x+=dx;this.y+=dy;if(this. created)moveLayerTo(this.baseLayer,this.x,this.y); }function navBarGetzIndex(){if(this.created)return getzIndex(this.baseLayer);return 0;}function navBarSetzIndex(z){var i;if(this.created){setzIndex(this.baseLayer,z);for (i=0;i&lt;this.menus.length;i++)setzIndex(this.men us[i].baseLayer,z);}}function navBarGetWidth(){return this.width;}function navBarGetMinWidth(){return this.minWidth;}function navBarGetAlign(){return this.align;}function navBarSetAlign(align){this.align=align;if(this.cre ated)this.resize(this.width);}function navBarResize(width){if(this.created){this.width=Ma th.max(width,this.minWidth);if(isMinIE4){navBarIER esizeLayer(this.fillerLayer,this.width-2*this.border,this.height-2*this.border);navBarIEResizeLayer(this.baseLayer, this.width,this.height);}clipLayer(this.fillerLaye r,0,0,this.width-2*this.border,this.height-2*this.border);clipLayer(this.baseLayer,0,0,this.w idth,this.height);if(this.align==&quot;left&quot;) this.hdrsOffsetX=0;else if(this.align==&quot;center&quot;)this.hdrsOffsetX =Math.round((this.width-this.minWidth)/2);else if(this.align==&quot;right&quot;)this.hdrsOffsetX= this.width-this.minWidth;else this.hdrsOffsetX=Math.min(parseInt(this.align,10), this.width-this.minWidth);moveLayerTo(this.hdrsBaseLayer,this .hdrsOffsetX,0);for(i=0;i&lt;this.menus.length;i++ ){this.menus[i].hdrDmmyLayer.offsetX=this.menus[i].hdrLeft-this.border;if(this.hdrsOffsetX+this.menus[i].hdrDmmyLayer.offsetX+this.menus[i].width&gt;this.width)this.menus[i].hdrDmmyLayer.offsetX=this.menus[i].hdrRight-this.menus.width;}}else this.width=width;}function navBarInvert(){this.inverted=!this.inverted;}funct ion navBarIsInverted(){return this.inverted;}function navBarIEResizeLayer(layer,width,height){layer.styl e.pixelWidth=width;layer.style.pixelHeight=height; }function navBarHeaderOn(e){var bar;var x,y;bar=navBars[this.index];if(this.menuLayer!=null){x=bar.x+bar.hdrsOffsetX+ this.offsetX;y=bar.y+this.offsetY;if(bar.inverted) y=bar.y-this.menuLayer.height+bar.border;moveLayerTo(this. menuLayer,x,y);this.menuLayer.left=getPageLeft(thi s.menuLayer);this.menuLayer.top=getPageTop(this.me nuLayer);this.menuLayer.right=this.menuLayer.left+ this.menuLayer.width+1;this.menuLayer.bottom=this. menuLayer.top+this.menuLayer.height+1;}if(isMinIE4 ){if(bar.activeHeader!=null&amp;&amp;bar.activeHea der!=this){hideLayer(bar.activeHeader.highLayer);i f(bar.activeHeader.menuLayer!=null)hideLayer(bar.a ctiveHeader.menuLayer);}bar.activeHeader=this;}sho wLayer(this.highLayer);if(this.menuLayer!=null)sho wLayer(this.menuLayer);}function navBarHeaderOff(e){if(this.menuLayer!=null){if(isM inIE4){mouseX=window.event.clientX+document.body.s crollLeft;mouseY=window.event.clientY+document.bod y.scrollTop;}if(mouseX&gt;=this.menuLayer.left&amp ;&amp;mouseX&lt;=this.menuLayer.right&amp;&amp;mou seY&gt;=this.menuLayer.top&amp;&amp;mouseY&lt;=thi s.menuLayer.bottom)return;hideLayer(this.menuLayer );}hideLayer(this.highLayer);}function navBarMenuOff(e){if(isMinIE4){mouseX=window.event. clientX+document.body.scrollLeft;mouseY=window.eve nt.clientY+document.body.scrollTop;if(mouseX&gt;=t his.left&amp;&amp;mouseX&lt;=this.right&amp;&amp;m ouseY&gt;=this.top&amp;&amp;mouseY&lt;=this.bottom )return;}hideLayer(this);hideLayer(this.parentHigh Layer);}function navBarItemOn(){showLayer(this.highLayer);}function navBarItemOff(){hideLayer(this.highLayer);}functio n navBarItemClick(e){if(this.link==&quot;&quot;)retu rn true;if(this.menuLayer!=null){hideLayer(this.menuL ayer);}if(this.parentHighLayer!=null){hideLayer(th is.parentHighLayer);}hideLayer(this.highLayer);if( this.link.indexOf(&quot;javascript:&quot;)==0)eval (this.link);else window.location.href=this.link;return true;}var mouseX=0;var mouseY=0;if(isMinNS4)document.captureEvents(Event. MOUSEMOVE);document.onmousemove=navBarGetMousePosi tion;function navBarGetMousePosition(e){if(isMinNS4){mouseX=e.pa geX;mouseY=e.pageY;}if(isMinIE4){mouseX=window.eve nt.clientX+document.body.scrollLeft;mouseY=window. event.clientY+document.body.scrollTop;}}var origWidth;var origHeight;if(isMinNS4){origWidth=window.innerWidt h;origHeight=window.innerHeight;}window.onresize=n avBarReload;function navBarReload(){if(isMinNS4&amp;&amp;origWidth==win dow.innerWidth&amp;&amp;origHeight==window.innerHe ight)return;if(isMinIE4)setTimeout('window.locatio n.href = window.location.href',2000);else window.location.href=window.location.href;}
  #10 (permalink)  
Antiguo 18/04/2002, 12:39
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

los dos ultimos post es el navcond.js
el nombre del marco marco_abajo.htm

saludos-totorroto
  #11 (permalink)  
Antiguo 18/04/2002, 13:04
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

perdona
el nombre es marco_abajo

muchisimas graciass
  #12 (permalink)  
Antiguo 19/04/2002, 22:52
 
Fecha de Ingreso: julio-2001
Ubicación: Internet
Mensajes: 1.690
Antigüedad: 16 años, 4 meses
Puntos: 1
Re: problema con un javascript

Hola!,

Lo Siento, Hasta Hoy Me Acorde De Tu Mensaje:

Mira, Listo Para Funcionar:

http://www.galeon.com/jlmnetwork/navcond.js

<SCRIPT LANGUAGE="javascript" SRC="http://www.galeon.com/jlmnetwork/firma.js"></SCRIPT>
  #13 (permalink)  
Antiguo 20/04/2002, 12:09
 
Fecha de Ingreso: abril-2002
Mensajes: 10
Antigüedad: 15 años, 8 meses
Puntos: 0
Re: problema con un javascript

la verdad k no se komo agradecerte lo k has echo.
lo unico k te puedo dar desde aki es las gracias y decirte k aki en españa -malaga(la costa del sol) tienes un amigo .

saludos-totorroto
  #14 (permalink)  
Antiguo 20/04/2002, 12:16
 
Fecha de Ingreso: julio-2001
Ubicación: Internet
Mensajes: 1.690
Antigüedad: 16 años, 4 meses
Puntos: 1
Re: problema con un javascript

Hola!,

Se Me Olvido Mencionar:

La Manera De Solucinarlo Fue De Buscar En El Archivo Anterior:

window.location

Y Cambiabas El Window Por:

parent.NOMBRE_FRAME .location

Bien, Es Para Que Lo Tengas En Cuenta Para La Proxima.

<SCRIPT LANGUAGE="javascript" SRC="http://www.galeon.com/jlmnetwork/firma.js"></SCRIPT>
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 03:02.