|
|
|

|

|
Dicas
|

|
ASP - Active Server Page (Miscelâneas)
|
|
 |
Título da Dica: Resolução do Browser
|
 |
|
|
Postada em 17/10/2003 por Mago_Pc
<% @Language = VBScript %> <% Option Explicit %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html> <head> <title>Browser Resolution Tester</title> <style type="text/css" media="screen"> .table { border : medium solid #669999; background-color : #FFCC99; } TH { font-family : Arial, Helvetica, sans-serif; font-size : 18px; font-weight : bold; background-color: #00CCFF; } </style>
<% If Len(Request.Form("btn")) Then %> <script language="javascript" type="text/javascript"> <!--- Hide window.open("<%= Request.Form("url") %>", "newWinObj", "<%= Request.Form("scrollbars") %><%= Request.Form("toolbar") %><%= Request.Form("status") %><%= Request.Form("resolution") %>") // ---> </script> <% End If %>
<script language="javascript" type="text/javascript"> function validForm(form1) { if(form1.url.value == "http://" || form1.url.value == "") { alert("Entre com a porra do endereço!"); form1.url.focus(); return false; } if(form1.resolution.value == 0) { alert("Expecifique a resolução!"); form1.resolution.focus(); return false; } } </script>
</head>
<body bgcolor="#006699"> <br><br>
<form action="<%= Request.ServerVariables("SCRIPT_NAME") %>" method="post" name="form1" onSubmit="return validForm(this)"> <table width="350" align="center" cellpadding="5" cellspacing="0" border="0"> <tr> <th>Browser teste de Resolução</th> </tr> <tr> <td bgcolor="#FFFFFF"> <strong>Por favor entre com o endereço web e marque as opções de resolução. </strong> <hr> </td> </tr>
<tr> <td align="center" bgcolor="#FFFFFF"> <input type="text" name="url" size="40" value="http://"> </td> </tr> <tr> <td align="center" bgcolor="#FFFFFF"> <select name="resolution"> <option value="0" SELECTED>Selecione a resolução da página</option> <option value="width=640,height=480">640X480</option> <option value="width=800,height=600">800X600</option> <option value="width=1024,height=800">1024X800</option> </select> </td> </tr> <tr> <td align="center" bgcolor="#FFFFFF"> <input type="checkbox" name="scrollbars" value="scrollbars,">Scrollbars <input type="checkbox" name="status" value="status,">Status Bar <input type="checkbox" name="toolbar" value="toolbar=yes,">Tool Bar </td> </tr> <tr> <td align="center" bgcolor="#FFFFFF"> <input type="Submit" name="btn" value="- ABRIR -"></td> </tr> </table> </form>
</body> </html>
|
|
|
|

|