Articulos PHP
Octubre 14, 2008, 08:33:21 *
Bienvenido(a), Visitante. Por favor, ingresa o regístrate.

Ingresar con nombre de usuario, contraseña y duración de la sesión
Noticias: Canciones Traducidas - Daforos.com - Fondos Gratis - Portatiles - Hosting - - Recursos Gratuitos Webmaster - elhacker dragonjar - sexo gratis - letras de canciones - Trucos Gratis - Juegos Gratis - Sexe gratuit - Juegos De Coche - porno - Start - Page0 - Page1 - Page2 - Page3 - Page4 - Page5 - Page6 - Page7 - Page8 - Page9 - Page10Page11 - Page12 - Page13 - Page14 - Page15 - Page16 - Page17 - Page18 - Page19 - Page20Page21 - Page22 - Page23 - Page24 - Page25 - Page26 - Page27 - Page28 - Page29 -

Páginas: 1   Ir Abajo
  Imprimir  
Autor Tema: Imágen volando por la pantalla  (Leído 1048 veces)
administrador
Administrator
Hero Member
*****
Desconectado Desconectado

Mensajes: 16876


Ver Perfil
« : Septiembre 16, 2004, 03:41:40 »

Con este Script conseguiras una imágen volando por la página de tu web.


<SCRIPT LANGUAGE="javaScript">
function setVariables(){
   if (navigator.appName == "Netscape") {
      horz=".left";
      vert=".top";
      docStyle="document.";
      styleDoc="";
      innerW="window.innerWidth";
      innerH="window.innerHeight";
      offsetX="window.pageXOffset";
      offsetY="window.pageYOffset";
      objectXY="layers[0]";
    }else{
      horz=".pixelLeft";
      vert=".pixelTop";
      docStyle="";
      styleDoc=".style";
      innerW="document.body.clientWidth"
      innerH="document.body.clientHeight"
      offsetX="document.body.scrollLeft"
      offsetY="document.body.scrollTop"
      objectXY="object1"
}
}
function checkLocation(){
imgwidth=79; // Anchura del logo en pixels
imgheight=70; // Altura del logo en pixels
var availableX=eval(innerW)
var availableY=eval(innerH)
var currentX=eval(offsetX)
var currentY=eval(offsetY)
xmax=availableX-(imgwidth+20)+currentX
ymax=availableY-(imgheight+20)+currentY
}
var x=-100;
var y=50;
var a=5;
var b=5;
function startMoveR(){
checkLocation();
x += a;
y += b;
if (y>ymax) b=b*-1
if (y<10) b=b*-1
evalMove();
if (xBR> else setTimeout("startMoveL()",100);
}
function startMoveL(){
checkLocation()
x -= a;
y += b;
if (y>ymax-15) b=b*-1
if (y<10) b=b*-1
evalMove();
if (x>0) setTimeout("startMoveL()",100);
else setTimeout("startMoveR()",100);
}
function evalMove(){
    eval(docStyle + objectXY + styleDoc + horz + "=" + x);
    eval(docStyle + objectXY + styleDoc + vert + "=" + y);
    //setTimeout("checkLocation()",10)
}
</SCRIPT>
<BODY ONLOAD="setVariables(),startMoveR()">
<DIV ID="object1" STYLE="position:absolute; visibility:show; left:-100px; top:50px; z-index:2">
<TABLE>
<TR>
<TD><IMG SRC="../../imatges/logo.gif" WIDTH="165" HEIGHT="66"></TD>
</TR>
</TABLE></DIV>
En línea
Páginas: 1   Ir Arriba
  Imprimir  
 
Ir a:  

Mas buscadas: apuntes audio belleza bolsa cancer carpet carrera casas computadora credito cross curso informatica divx dolar drivers e mule economia explorer grafica hardware higiene industria industrial informatica internet libros linux mantenimiento manuales media medicina nutricion online paginas web politica posicionamiento programacion red red alert salud seguro seo software tecnologia trucos windows universidad venta video web windows winrar

UseBB Port by Gaia Modified & Upgraded by Croco Articulos PHP | Impulsado por SMF 1.1.6.
© 2005, Simple Machines LLC. Todos los Derechos Reservados.

Página creada en 0.107 segundos con 19 consultas.