Stranice: [1]   Idi dole
Štampaj
Autor Tema: Typing Text Script  (Pročitano 762 puta)
.stoRe
Mozak foruma
******

Ugled: 0
Van mreže Van mreže

Poruke: 1.194


Linux Rules! :)


« poslato: Oktobar 13, 2008, 08:41:07 am »

Korak 1: Убаците код испод у Head  твојој  у страници

Kod:
<script type="text/javascript" src="TypingText.js">
/****************************************************
* Typing Text script- By Twey @ Dynamic Drive Forums
* Visit Dynamic Drive for this script and more: http://www.dynamicdrive.com
* This notice MUST stay intact for legal use
****************************************************/
</script>

   
Корак 2: Затим, једноставно додате испод узорак ХТМЛ на своју страну, што показује како створити Куцање текст из двије произвољне садржаја на страници

Kod:
<div id="example1">Thanks for visiting <a href="http://www.dynamicdrive.com/">Dynamic Drive!</a>
Wow, HTML gets properly typed out too!</div>

<p id="example2">This text has a <b>slashing cursor</b> at the end. <br />And this is on a new line, thanks to the <br> tag.</p>

<script type="text/javascript">
//Define first typing example:
new TypingText(document.getElementById("example1"));

//Define second typing example (use "slashing" cursor at the end):
new TypingText(document.getElementById("example2"), 100, function(i){ var ar = new Array("\\", "|", "/", "-"); return " " + ar[i.length % ar.length]; });

//Type out examples:
TypingText.runAll();
</script>
Sačuvana



Stranice: [1]   Idi gore
Štampaj
Prebaci se na:  

Naša mreža: Bg-dizajn.com | AstaHost | Anonimus | My Exploit | Lovac Na Novac | RE.rs
Partneri: Net Centar | EE.RS portal | Maturski | Svet Igara