Autor | Zpráva | ||
---|---|---|---|
Alastor_Kopal Profil * |
#1 · Zasláno: 15. 1. 2009, 14:30:03
Chtěl jsem si dát na web takovou blbůstku - nějaký zářivý text a tak to mám v java scriptu ale mám černý pozadí a to písmo je taky černé jak bych ho mohl přebarvit ?
|
||
Alastor_Kopal Profil * |
#2 · Zasláno: 15. 1. 2009, 14:30:36
<script language="JavaScript"> <!-- var text = "Registrované školy"; var msg = "<span style='font-size: 25px; visibility: hidden;'>.</span>"; function animace(index) { for (i = 0; i < text.length; i++) { if (index == (i - 3)) { msg += "<span style='font-size: 36px; color: #ff0000;'>" + text.charAt(i) + "</span>"; } else if (index == (i - 2)) { msg += "<span style='font-size: 40px; color: #ff6600;'>" + text.charAt(i) + "</span>"; } else if (index == (i - 1)) { msg += "<span style='font-size: 43px; color: #ffcc00;'>" + text.charAt(i) + "</span>"; }else if (index == i) { msg += "<span style='font-size: 45px; color: #ffff00;'>" + text.charAt(i) + "</span>"; } else if (index == (i + 1)) { msg += "<span style='font-size: 43px; color: #ffcc00;'>" + text.charAt(i) + "</span>"; } else if (index == (i + 2)) { msg += "<span style='font-size: 40px; color: #ff6600;'>" + text.charAt(i) + "</span>"; } else if (index == (i + 3)) { msg += "<span style='font-size: 36px; color: #ff0000;'>" + text.charAt(i) + "</span>"; } else { msg += "<span style='font-size: 52px;'>" + text.charAt(i) + "</span>"; } } anim.innerHTML = msg; msg = "<span style='font-size: 25px; visibility: hidden;'>.</span>"; if (index >= text.length) { index = 0; } else { index++; } window.setTimeout("animace(" + index + ")", 100); } // --> </script> </head> <body OnLoad="animace(0);"> <br><br> <center> <div id="anim" style="font-family: Verdana; font-weight: bold: color; #ff0000";></div> </center> kde by měla být chyba ? |
||
Vydrus Profil * |
Proč sem dáváš takovouhle kravinu? Pokud nevíš, jak změnit barvu, projdi si něco na JPW ohledně zapisování barev číslem.
|
||
Časová prodleva: 3 měsíce
|
|||
zvěřiňák Profil * |
#4 · Zasláno: 8. 4. 2009, 23:04:04
Máš tam jenom drobnou chybku, jinak to funguje dobře.
<div id="anim" style="font-family: Verdana; font-weight: bold: color; #ff0000";></div> Má tam být: <div id="anim" style="font-family: Verdana; font-weight: bold; color: #ff0000";></div> |
||
Časová prodleva: 15 let
|
0