Si eso ya lo veo, pero estás mezclando variables de javascript con codigo de servidor, cosa que no puedes. Deberías hacerlo así:
Código:
<html>
<head>
<title>Documento sin título</title>
</head>
<body>
<script language="javascript">
var hz=window.screen.height;
var wz=window.screen.width;
document.write("La resolución de la pantalla es:<br>");
document.write("Ancho: " + wz + "<br>");
document.write("Alto: " + hz + "<br>");
if (wz<800)
{
document.getElementById('tabla1').style.display='inline';
document.getElementById('tabla2').style.display='none';
}
else
{
document.getElementById('tabla1').style.display='none';
document.getElementById('tabla2').style.display='inline';
}
</script>
<table width="780" border="0" cellspacing="0" cellpadding="0" id="tabla1">
<tr>
<td>Esta es la resolución de 800 </td>
</tr>
</table>
<table width="780" border="0" cellspacing="0" cellpadding="0" id="tabla2">
<tr>
<td>Esta es la resolución de más de 800 </td>
</tr>
</table>
</body>
</html>
Responder Con Cita