Ver Mensaje Individual
  #5 (permalink)  
Antiguo 07/01/2005, 08:13
antoli
 
Fecha de Ingreso: enero-2005
Mensajes: 50
Antigüedad: 20 años, 4 meses
Puntos: 0
Venga estoy en ello, lo que pasa es que me da error el javascript en secuencia de comandos LÍNEA 126, que es exactamente debajo de donde esta el onchange, te paso lo que tengo hecho hasta ahora a ver si voy bien encaminado.
Gracias.

SOLCONTRA.ASP

Código:
<HTML>
<HEAD>
<META NAME="Generator" CONTENT="Microsoft FrontPage 5.0">
<TITLE>Solicitud de Registro WPP.</TITLE>
<script language="JavaScript">
<!--
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
//  End -->
</script>
</HEAD>
<BODY TEXT="#ffffff" LINK="#008080" VLINK="#008080" ALINK="#008080" BGCOLOR="#000000">
<form name="frm_alta" method="post" action="http://www.webp***l.net/**/register.asp" OnSubmit="return check();">
<CENTER>
<TABLE WIDTH="355" BORDER="1" CELLSPACING="0" CELLPADDING=0" bgcolor="#C0C0C0" height="200">
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Nombre:</font><TD width="335" height="23"><font size="2">
  <!--webbot bot="Validation" s-display-name="Nombre" s-data-type="String" b-allow-letters="TRUE" b-allow-whitespace="TRUE" b-value-required="TRUE" i-minimum-length="1" i-maximum-length="20" --><INPUT TYPE="text" SIZE="17" NAME="nombre" BORDER="1" maxlength="20" style="border-style: inset; border-width: 2; background-color: white">
    </font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Apellido1:</font></center><TD width="335" height="23">
  <p align="left"><font size="2">
  <!--webbot bot="Validation" s-display-name="Apellido 1º" s-data-type="String" b-allow-letters="TRUE" b-allow-whitespace="TRUE" b-value-required="TRUE" i-minimum-length="1" i-maximum-length="50" --><INPUT TYPE="text" SIZE="25" NAME="apellido1" BORDER="1" maxlength="50" style="border-style: inset; border-width: 2; background-color: white"></font><TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Apellido2:</font><TD width="335" height="23"><font size="2">
  <!--webbot bot="Validation" s-display-name="Apellido 2º" s-data-type="String" b-allow-letters="TRUE" b-allow-whitespace="TRUE" b-value-required="TRUE" i-minimum-length="1" i-maximum-length="50" --><INPUT TYPE="text" SIZE="25" NAME="apellido2" BORDER="1" maxlength="50" style="border-style: inset; border-width: 2; background-color: white">
    </font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">DNI:</font><TD width="335" height="23">
    <p align="left"><font size="2">
    <!--webbot bot="Validation" s-display-name="DNI" s-data-type="Integer" s-number-separators="x" b-value-required="TRUE" i-minimum-length="6" i-maximum-length="8" --><INPUT SIZE="7" NAME="dni" BORDER="1" maxlength="8" style="border-style: inset; border-width: 2; background-color: white">&nbsp;</font><font size="3" color="#0000A0"><sup>
    </sup></font><font face="Serifa BT" size="3"><sup><font color="#0000A0">*</font> 
    </sup></font><font color="#0000A0" size="3"><sup>
    Ocho dígitos sin puntos y
    sin letra.</sup></font>
<TR> 
<TD width="73" height="23">
<p align="justify"><font size="2" face="Arial" color="#000080">Cuerpo:</p>
</font></TD> 
<TD width="335" height="23">
<p align="left">
<SELECT NAME="cuerpo" style="border-style: inset; border-width: 2; background-color: white" onChange="location.href(solcontra.asp?cuerpo=' + frm_alta.cuerpo.options[frm_alta.cuerpo.selectedIndex].value">
<OPTION VALUE="Guardia Civil">Guardia Civil 
<OPTION VALUE="Policía Nacional">Policía Nacional
<OPTION VALUE="Policía Autonómica">Policía Autonómica 
<OPTION VALUE="Policía Local">Policía Local
<OPTION VALUE="Otros Cuerpos">Otros Cuerpos
</SELECT><font color="#0000A0" size="3" face="Serifa BT"><sup>* </sup></font><font color="#0000A0" size="3"><sup>Seleccione una
opción.</sup></font></p>
</TD> 
<% 
 
   dni = Request.Form("dni") 
   cuerpo = Request.Form("cuerpo")
    
   'Abre la conexion con la base de datos a traves de una conexion ODBC 
   Set Conn = Server.CreateObject("ADODB.Connection")
   Conn.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & server.MapPath("/*****/register.mdb")
   Set RS = Server.CreateObject ("ADODB.RecordSet")   
sql = "SELECT * FROM escalafon WHERE dni="& dni  &" and cuerpo='" &  cuerpo & "'"
   RS.Open sql, Conn
   'Si el valor EOF (fin de la tabla elegida) es verdadero, no existe el dni.
   If (RS.EOF = false) then
   set RS=nothing
   
   Else
      Response.Write "<br><br><div align=center><u>2.000/2.005 | 5º Aniversario WPP.</div><br><br>"
      Response.Write "<div align=justify>No es guardia civil en activo. Lea estas circustancias para solucionar su problema.</div><br><br></u>"
      Response.Write "<div align=justify><font color=#DADADA>1.-</font>Si introdujo su dni <u><font color=red>" & Request.Form("dni") & "</u></font> incorrectamente, vuelva atras, e intentelo de nuevo.</div>"
      Response.Write "<div align=justify><font color=#DADADA>2.-</font>Si es Guardia Civil en Reserva y/o Retirado o pertenece a cualquier otro cuerpo policial, haga click en el boton inferior -No Guardia Civil Activo-.<form name='tuformulario' FORM ACTION='https://www.secureheaven.com/ssl/ssl-wpp.com.ar/solcontra_nogc.html' target=_self METHOD=GET><p style='margin-top: 1'><b><input type='submit'  value='No Guardia Civil Activo' style='border:1px solid #FFFFFF; font-size: 10px; background-color: #408080; color: #FFFFFF; font-family: Verdana; '></font></b></form><br><br>"
  	  Response.Write "<div align=center><a href=javascript:window.close(); title='CERRAR VENTANA'><b><font face='Flat Brush' color=#008080 style=font-size:10pt><u>CERRAR VENTANA</u></font></b></em></a></span>"
   End If

   'Libera memoria 
   Conn.Close 
   Set Conn= Nothing 
%> 

</TR><TR><TD width="73" height="23">
    <p align="justify"><font size="2" face="Arial" color="#000080">Localidad:</font><TD width="335" height="23"><font size="2">
  <!--webbot bot="Validation" s-display-name="Destino" s-data-type="String" b-allow-letters="TRUE" b-allow-whitespace="TRUE" b-value-required="TRUE" i-minimum-length="1" i-maximum-length="50" --><INPUT TYPE="texT" SIZE=39 NAME="destino" BORDER="1" maxlength="50" style="border-style: inset; border-width: 2; background-color: #white">
    </font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Provincia:</font><TD width="335" height="23"><font size="2">
  <!--webbot bot="Validation" s-display-name="Provincia" s-data-type="String" b-allow-letters="TRUE" b-allow-whitespace="TRUE" b-value-required="TRUE" i-minimum-length="1" i-maximum-length="30" --><INPUT SIZE=17 NAME="provincia" BORDER="1" maxlength="30" style="border-style: inset; border-width: 2; background-color: white">
    </font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">E-mail:</font><TD width="335" height="23">
    <p align="left"><font size="2">
    <!--webbot bot="Validation" s-display-name="Email" s-data-type="String" b-allow-letters="TRUE" b-allow-digits="TRUE" b-value-required="TRUE" i-minimum-length="5" i-maximum-length="50" --><INPUT SIZE="25" NAME="email" BORDER="1" maxlength="50" style="border-style: inset; border-width: 2; background-color: white">
    </font>
    <font color="#0000A0" size="3" face="Serifa BT"><sup>* </sup></font><font color="#0000A0" size="3"><sup>E-mail
    válido.</sup></font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Usuario:</font><TD width="335" height="23">
    <p align="left"><font size="2">
    <!--webbot bot="Validation" s-display-name="usuario" b-value-required="TRUE" i-minimum-length="4" i-maximum-length="12" --><INPUT SIZE="15" NAME="usuario" BORDER="1" maxlength="12" style="border-style: inset; border-width: 2; background-color: white">
    </font><font color="#0000A0" size="3" face="Serifa BT"><sup>* </sup></font><font color="#0000A0" size="3"><sup>Entre 4 y 12 dígitos.</sup></font>
<TR><TD width="73" height="23"><font size="2" face="Arial" color="#000080">Clave:</font><TD width="335" height="23">
    <p align="left"><font size="2">
    <!--webbot bot="Validation" s-display-name="clave" b-value-required="TRUE" i-minimum-length="4" i-maximum-length="12" --><INPUT SIZE="15" NAME="clave" BORDER="1" maxlength="12" style="border-style: inset; border-width: 2; background-color: white">
    </font><font color="#0000A0" size="3" face="Serifa BT"><sup>* </sup></font><font color="#0000A0" size="3"><sup>Entre 4 y 12 dígitos.</sup></font>
<TR><TD width="462" colspan="2">
    <p align="left" style="line-height: 100%; margin-top: 3">&nbsp;&nbsp; 
    <input type="checkbox" name="acceptconds" value="ON">&nbsp;
    <font color="#0000A0" size="3"><sup>* Acepto las condiciones legales.&nbsp; <a href="javascript:;" onClick="MM_openBrWindow('../condicioneswpp.html','','scrollbars=yes,toolbar=no,resizable=no,width=400,height=400,left=220,top=100')" title="Ver condiciones">Ver condiciones.</a></sup></font>
</TABLE>
<p style="margin-top: 3">
<INPUT TYPE="submit" VALUE="Enviar" style="background-color: #008080; color: #FFFFFF; font-family: Verdana; font-size: 8 pt; border-style: outset">
<INPUT TYPE="reset" VALUE="Borrar" style="background-color: #008080; color: #FFFFFF; font-family: Verdana; font-size: 8 pt; border-style: outset">
</form>
</form>
<div ALIGN="CENTER"><strong><a href="javascript:window.history.back()"><img src="izda.gif" border="0" alt="VOLVER ATRÁS"></A></div>
<div ALIGN="CENTER"><FONT SIZE="-1" COLOR="white"><EM>©&nbsp; Web
  Policial Profesional WPP&nbsp; 2.003</EM></FONT></div>
</BODY>

Última edición por antoli; 07/01/2005 a las 08:21