//Forever Imperfect
Tutorial: Text Online Header

Kamis, 28 Agustus 2014 @ 20.04 | 1 Comment [s]


Aku mau posting tutorial lagi nih. Aku dapet dari blognya Kak Salsa. Text online header adalah tulisan header yang berkelap-kelip.




Template Designer : Paste di Html/Javascript.
Blogskins : Paste di bawah kode </style>

<style>
#tittle3 {text-align: center;margin-top:20px;font: normal 60px "candystr";}
@font-face{font-family:candystr;src:url('http://static.tumblr.com/eq1rpir/i3Wm518mw/candystr.ttf')}
</style>
<center>
<script type="text/javascript">
var bgcolour="#ffffff";
var fgcolour="#FF94B8";
var speed=50;
var shades=10;
var bubbcol=new Array();
var bubbler, bubbtxt;
var bubbchr=new Array();
window.onload=function() { if (document.getElementById) {
  for (bubbler=0; bubbler<=shades; bubbler++) {
    bubbtxt="#";
    for (var i=1; i<6; i+=2) {
      var bg=parseInt(bgcolour.substring(i,i+2),16);
      bubbtxt+=dechex(Math.floor(bg+(parseInt(fgcolour.substring(i,i+2),16)-bg)*(bubbler/shades)));
    }
    bubbcol[bubbler+1]=bubbtxt;
  }
  bubbler=document.getElementById("bubble");
  bubbtxt=bubbler.firstChild.nodeValue;
  while (bubbler.childNodes.length) bubbler.removeChild(bubbler.childNodes[0]);
  for (var i=0; i<bubbtxt.length; i++) {
    var bubbi=document.createElement("span");
    bubbi.setAttribute("id", "bubb"+i);
    bubbi.appendChild(document.createTextNode(bubbtxt.charAt(i)));
    bubbler.appendChild(bubbi);
  }
  bubbler=setInterval ("bubbling()", speed);
}}

function dechex(dec) {
  var hex=dec.toString(16);
  if (dec<16) return "0"+hex;
  else return hex;
}

function bubbling() {
  for (var i=0; i<bubbtxt.length; i++) {
    var bubbme=document.getElementById("bubb"+i);
    if (bubbchr[i]) {
      bubbme.style.color=bubbcol[bubbchr[i]];
      bubbchr[i]=(bubbchr[i]+1)%bubbcol.length;
    }
    else if (Math.random()<0.75/bubbchr.length) bubbchr[i]=1;
  }
}
// ]]>
</script>
<div id="tittle3">
<span id="bubble">THIS IS AN EXAMPLE</span></div>
</center>

Lalu, ubah kode yang berwarna merah dengan kode warna kesukaanmu dan ubah kode yang berwarna biru dengan tulisan sesukamu!

  credit code : Afiqah Junizan



Older Post | Newer Post
The Disclaimer

Hi peeps. Im Fasya, 10 years old. My hobby is blogging, writing, ex-link, and reading. Please dont open my page source!

underlined, bold

Dreamer!


Navigations!

Diary About Site


Let's Talk!

No Anonymous
No Spamming
No Rusuh
Chat with me!


The Credits!

Template by : Farisyaa Awayy
Basecode by : Nurynn
Full Edited : Fasya

Best View at GOOGLE CHROME!