File tree Expand file tree Collapse file tree 3 files changed +12
-8
lines changed
Expand file tree Collapse file tree 3 files changed +12
-8
lines changed Original file line number Diff line number Diff line change 1212
1313 < div id ="contenedor ">
1414 < div id ="central ">
15- < div id ="login ">
15+ < div id ="formlogin ">
1616 < div class ="titulo ">
1717 Acceso Usuario
1818 </ div >
Original file line number Diff line number Diff line change 1010< body >
1111 < div class ="formContainer ">
1212 < div class ="menu ">
13- < button id ="login " class ="btnLogin " onclick ="mostrarLogin() "> Login </ button >
14- < button id ="register " class ="btnRegistro " onclick ="mostrarRegistro() "> Registro</ button >
13+ < button id ="login " class ="btnLogin " onclick ="mostrarLogin() "> Login </ button >
14+ < button id ="register " class ="btnRegistro " onclick ="mostrarRegistro() "> Registro</ button >
1515 </ div >
1616 < div id ="contenido ">
1717
1818 <!-- USADO PARA PUEBAS -->
1919
20- <!-- <div id="formlogin">
20+ <!-- <div id="formlogin">
2121 <h2>Iniciar Sesión</h2>
2222 <form action="#">
2323 <input type="text" id="GetUsuario" placeholder="Usuario" required>
2424 <input type="password" id="GetPass" placeholder="Contraseña" required>
2525 <input type="submit" id="login" value="Iniciar Sesión" onclick="validacion()">
2626 <div id="mensajeLogin"></div>
2727 </form>
28+ <button id="register" class="btnRegistro" onclick="mostrarRegistro()">Registro</button>
2829 </div>
29- <div class="formregistro">
30+
31+
32+
33+ <div class="formregistro">
3034 <h2>Crea tu Cuenta</h2>
3135 <form action="#">
3236 <input type="text" id="SetNombre" placeholder="Nombre" required>
Original file line number Diff line number Diff line change 6666 </form>
6767 </div>
6868 ` ;
69-
69+ event . preventDefault ( )
7070 /*
7171 * OPERADOR TERNARIO
7272 */
8181
8282 function mostrarRegistro ( ) {
8383 let docuRegister = document . getElementById ( 'contenido' ) ;
84-
84+
8585 document . getElementById ( 'contenido' ) . innerHTML = `
8686 <div id="formregistro">
8787 <h2>Crea tu Cuenta</h2>
130130
131131 //localStorage.removeItem('usuarios');//boorar localstorage
132132 console . log ( 'LocalStorage borrado.' ) ;
133- window . location . href = "./principal .html" ; //redirecciona a pagina. NO FUNCIONA AUN
133+ window . location . href = "./carrito .html" ; //redirecciona a pagina. NO FUNCIONA AUN
134134 }
135135 else { document . querySelector ( '#mensajeLogin' ) . innerText = "Datos incorrectos" ; }
136136
You can’t perform that action at this time.
0 commit comments