I found something i like on Tumbler and tried to recreate it.. but i have a problem.
this is what im trying to clone: http://cl.vc/Beta/Tumbler/
and this is what i have: http://cl.vc/Beta/Tumbler/test.html
HTML:
<form method="post" name="form" id="form">
<span id="myText"><p hidden>good</p></span>
<input type="text" id="input" name="input" value="" onkeypress="showtext();"/>
JavaScript:
function showtext() {
var inputlength = document.getElementById('input').value.length;
var string = "";
for (var i = 0; i <= inputlength; i++) {
var string = string + " ";
}
document.getElementById('myText').innerHTML = string + "cl.vc";
document.getElementById('myText').style.zIndex = "2";
}
the problem is that the space is not the same as if you type in hhhhh or iiiiii because the size of the letter is different.. i also would like if to take away the space if you delete the text..