The Pet Button
Here's the script that makes the Pet Button seen on the main page. Just copy it and put it into the HTML of your page. You do NOT have to give Bumderland credit for this if you do not want to.
<script language="JavaScript"><!--
n=0;
// --></script><script
language="JavaScript"><!--
function petted(){
if(n==1){
document.myform.mytext.value="Thanks."
};
if(n==2){
document.myform.mytext.value="Thanks again.";
document.myform.butt.value="Have a good day."
};
if(n==3){
document.myform.mytext.value="Okay. That's enough.";
document.myform.butt.value="Please, not again."
};
if(n==4){
document.myform.mytext.value="Ow! Knock it off!";
document.myform.butt.value="Leave me alone!"
};
if(n==5){
document.myform.mytext.value="Ack! Cough! Wheeze!";
document.myform.butt.value="..."
};
if(n==6){
document.myform.mytext.value="I can't take much more of
this...";
document.myform.butt.value="Please, spare my life..."
};
if(n==7){
document.myform.mytext.value="Have you no sympathy!";
document.myform.butt.value="Go away!"
};
if(n==8){
document.myform.mytext.value="One more time, and you are
history!";
document.myform.butt.valued="Pet me! I dare you!";
alert("Dear annoying person,\n As the leader of the Abused
Pet Buttons Organization, I must inform you that further abuse of
this button will result in your ejection from this site. I hope
you rot in Heck (I will not resort to cursing)!")
};
if(n==9){
parent.location=history[history.length-1]
};
}
// -->
</script>
<form name="myform">
<p><input type="button" name="butt"
value=" Pet Me "
onClick="n=n+1; petted()"> <input
type="text" size="45" name="mytext"
value=" "
onChange="document.myform.mytext.value='Sure. Just type in
my box.'">
</form>
Here's what the script does: