+ Javascript precarga reorientar página html

  • HKt0p5
  • Graduate
  • Graduate
  • Avatar de Usuario
  • Registrado: Mar 19, 2008
  • Mensajes: 134
  • Loc: Bulgaria
  • Status: Offline

Nota Agosto 15th, 2008, 9:24 am

¿Cuál es el código para hacer lo siguiente:
Theres una página html que espera un poco,
entonces automáticamente precargarlas / redirecciones a
otra página HTML?
  • Anonymous
  • Bot
  • No Avatar
  • Registrado: 25 Feb 2008
  • Mensajes: ?
  • Loc: Ozzuland
  • Status: Online

Nota Agosto 15th, 2008, 9:24 am

  • gonzoka
  • Student
  • Student
  • No Avatar
  • Registrado: Jul 30, 2005
  • Mensajes: 75
  • Loc: Bristol, UK
  • Status: Offline

Nota Agosto 15th, 2008, 9:40 am

Esto es posible de hacer, pero mucho más sencillo y amigable navegador para hacer uso de cabeceras HTTP lugar. Ver http://webdesign.about.com/od/metatagli ... 80300a.htm lo que explica cómo utilizar estos - ponerlos dentro de la <head> en su etiqueta html.
  • HKt0p5
  • Graduate
  • Graduate
  • Avatar de Usuario
  • Registrado: Mar 19, 2008
  • Mensajes: 134
  • Loc: Bulgaria
  • Status: Offline

Nota Agosto 15th, 2008, 9:46 am

Así que simplemente ajustar y ésta
Código: [ Select ]
<meta http-equiv="refresh" content="2;url=http://webdesign.about.com">

en mi <head> HTML, ¿verdad? Gracias!
  • graphixboy
  • Control + Z
  • Mastermind
  • Avatar de Usuario
  • Registrado: Jul 11, 2005
  • Mensajes: 1828
  • Loc: In the Great White North
  • Status: Offline

Nota Agosto 15th, 2008, 12:07 pm

derecho
If at first you don't succeed F1... If that doesn't work try Google!
//// Designer, Developer & Teacher - Interactive, Motion and 3D \\\\
Portfolio at WhenImNotSleeping.com
  • videoediting-direct
  • Beginner
  • Beginner
  • No Avatar
  • Registrado: Jul 28, 2008
  • Mensajes: 53
  • Loc: United Kingdom
  • Status: Offline

Nota Agosto 16th, 2008, 4:40 am

Código: [ Select ]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
ZHTML>
<HEAD>
<TITLE> New Document </TITLE>
<script language="javascript">
    function Redirectfun()
    {
self.setInterval('clock()', 1000*60*3)
window.location="htmlpage.html";
    }
    </script>
</HEAD>

ZBODY onload="Redirectfun()";>

</BODY>
</HTML>
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
  2. ZHTML>
  3. <HEAD>
  4. <TITLE> New Document </TITLE>
  5. <script language="javascript">
  6.     function Redirectfun()
  7.     {
  8. self.setInterval('clock()', 1000*60*3)
  9. window.location="htmlpage.html";
  10.     }
  11.     </script>
  12. </HEAD>
  13. ZBODY onload="Redirectfun()";>
  14. </BODY>
  15. </HTML>
  • righteous_trespasser
  • Scuffle
  • Genius
  • Avatar de Usuario
  • Registrado: Mar 12, 2007
  • Mensajes: 6228
  • Loc: South-Africa
  • Status: Offline

Nota Agosto 17th, 2008, 11:02 pm

VD...¿no le parece que el HTML es mejor? porque la gente podría tener javascript discapacitados y el modo HTML es menor...
Let's leave all our *plum* where it is and go live in the jungle ...
  • videoediting-direct
  • Beginner
  • Beginner
  • No Avatar
  • Registrado: Jul 28, 2008
  • Mensajes: 53
  • Loc: United Kingdom
  • Status: Offline

Nota Agosto 18th, 2008, 6:01 am

Aquí va cosas HTML;

Código: [ Select ]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE> New Document </TITLE>
<meta http-equiv="Refresh" content="5;url=http://www.test.com">
<META NAME="Generator" CONTENT="EditPlus">
<META NAME="Author" CONTENT="">
<META NAME="Keywords" CONTENT="">
<META NAME="Description" CONTENT="">
</HEAD>

<BODY>
<!-- PLACE YOUR BODY CONTENT HERE -->
</BODY>
</HTML>
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
  2. <HTML>
  3. <HEAD>
  4. <TITLE> New Document </TITLE>
  5. <meta http-equiv="Refresh" content="5;url=http://www.test.com">
  6. <META NAME="Generator" CONTENT="EditPlus">
  7. <META NAME="Author" CONTENT="">
  8. <META NAME="Keywords" CONTENT="">
  9. <META NAME="Description" CONTENT="">
  10. </HEAD>
  11. <BODY>
  12. <!-- PLACE YOUR BODY CONTENT HERE -->
  13. </BODY>
  14. </HTML>

Es necesario añadir la etiqueta meta en la cabecera
<meta http-equiv="refresh" content="5;url=http://www.test.com"> y sustituir la www.test.com con su URL. Esto esperar 5 segundos y luego será redirigido a la URL especificada.
  • righteous_trespasser
  • Scuffle
  • Genius
  • Avatar de Usuario
  • Registrado: Mar 12, 2007
  • Mensajes: 6228
  • Loc: South-Africa
  • Status: Offline

Nota Agosto 18th, 2008, 6:11 am

Exactamente como dijo graphixboy, VD, quizás tan sólo añadir algunos [code] etiquetas alrededor de pedazos de código para que sea más fácil de leer...
Let's leave all our *plum* where it is and go live in the jungle ...
  • HKt0p5
  • Graduate
  • Graduate
  • Avatar de Usuario
  • Registrado: Mar 19, 2008
  • Mensajes: 134
  • Loc: Bulgaria
  • Status: Offline

Nota Agosto 19th, 2008, 5:31 pm

Malos sólo se adhieren a la meta de un (^ ^)

Publicar Información

  • Total de mensajes en este tema: 9 mensajes
  • Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 122 invitados
  • No puede abrir nuevos temas en este Foro
  • No puede responder a temas en este Foro
  • No puede editar sus mensajes en este Foro
  • No puede borrar sus mensajes en este Foro
  • No puede enviar adjuntos en este Foro
 
 

© 2011 Unmelted, LLC. Ozzu® es una marca registrada de Unmelted, LLC