Ver Mensaje Individual
  #2 (permalink)  
Antiguo 03/08/2002, 18:23
LuisDJ
 
Fecha de Ingreso: marzo-2002
Ubicación: No se!
Mensajes: 121
Antigüedad: 22 años, 1 mes
Puntos: 1
Re: Detectar la resolucion de pantalla

Hola!!!

En el Deposito de JS vienen un par de ejemplos de lo ke buscas.

Ahi van:

<!-- Detectar y redireccionar segun resolución de pantalla -->

<script LANGUAGE="JavaScript">

function redireccionar() {
var url640x480 = "http://www.tu-sitio.com/640x480";
var url800x600 = "http://www.tu-sitio.com/800x600";
var url1024x768 = "http://www.tu-sitio.com/1024x768";
if ((screen.width == 640) && (screen.height == 480))
window.location.href= url640x480;
else if ((screen.width == 800) && (screen.height == 600))
window.location.href= url800x600;
else if ((screen.width == 1024) && (screen.height == 768))
window.location.href= url1024x768;
else window.location.href= url640x480;
}

</script>

<!-- Maximizar ventana -->

<script language="JavaScript">
<!--

// Maximizar Ventana por Nick Lowe ([email protected])

window.moveTo(0,0);
if (document.all) {
top.window.resizeTo(screen.availWidth,screen.avail Height);
}
else if (document.layers||document.getElementById) {
if (top.window.outerHeight<screen.availHeight||top .window.outerWidth<screen.availWidth){
top.window.outerHeight = screen.availHeight;
top.window.outerWidth = screen.availWidth;
}
}
//-->
</script>

Espero te sirvan!!!

Bye ;)