Cheerleader Animation
This script will display an attractive and nice-looking animation of cheerleader just by using text. You can use this animation as your AJAX progress indicator or you may just put it on a side of your webpage to make your webpage attractive.
Platform
This script can be run well using Mozilla Firefox (any version), Internet Explorer (any version), Opera and Fast Browser.
Preview
Source Code
[html]<html>
<head>
<title>Cheerleader Animation</title>
<script language="JavaScript">
// By : Isusx Programming Corner
// URL : http://isusx.com
var u_agent = navigator.userAgent.toLowerCase();
if (u_agent.indexOf("mac") != -1)
var crlf = "\r";
else
var crlf = "\n";
var max = 0;
function frame_list(){
max = frame_list.arguments.length;
for (i=0;i<max;i++)
this[i] = frame_list.arguments[i];
}
fr = new frame_list(
" o" + crlf +
" /|\\" + crlf +
" */ \\*" + crlf,
" o_" + crlf +
" \<| *" + crlf +
" *\>\\" + crlf,
" _o/*" + crlf +
" * |" + crlf +
" / \\" + crlf,
" *\o_" + crlf +
" / *" + crlf +
" \<\\" + crlf,
" _o/*" + crlf +
" * |" + crlf +
" / \\" + crlf,
" *\\c/*" + crlf +
" )" + crlf +
" / \>" + crlf,
" *" + crlf +
" \\__/c" + crlf +
" \> \\*" + crlf,
" __/" + crlf +
" (o_*" + crlf +
" \\*" + crlf,
" \\ /" + crlf +
" |" + crlf +
" */o\\*" + crlf,
" \\_" + crlf +
" (" + crlf +
" */o\\*" + crlf,
" \<_" + crlf +
" __(" + crlf +
" * o|*" + crlf,
" /_" + crlf +
" __(" + crlf +
" * o|*" + crlf,
" ___" + crlf +
" *\/ \>" + crlf +
" o|*" + crlf,
" *" + crlf +
" o|_/" + crlf +
" */ \\" + crlf,
" *" + crlf +
" _o|_" + crlf +
" * \>\\" + crlf,
" _o/*" + crlf +
" * |" + crlf +
" / \\" + crlf,
" *\\o/*" + crlf +
" |" + crlf +
" / \\" + crlf,
" c/*" + crlf +
" \<\\" + crlf +
" */\\" + crlf,
" c__" + crlf +
" \<\ *" + crlf +
" */\\" + crlf,
" c__" + crlf +
" /\ *" + crlf +
" * /\>" + crlf,
" c/*" + crlf +
" /(__" + crlf +
" * /" + crlf,
" __o/*" + crlf +
" * (__" + crlf +
" \<" + crlf,
" __o_" + crlf +
" * / *" + crlf +
" \<\\" + crlf,
" *_o_" + crlf +
" | *" + crlf +
" \< \\" + crlf,
" *_c_*" + crlf +
" |" + crlf +
" \>\\" + crlf,
" *_c_*" + crlf +
" |__" + crlf +
" \>" + crlf,
" *_c_*" + crlf +
" __|__" + crlf +
"" + crlf,
" " + crlf +
" *_c_*" + crlf +
" __)__" + crlf,
" " + crlf +
" *\\c/*" + crlf +
" __)__" + crlf
);
var x=0;
function animate_cheerleader() {
var stage = document.getElementByID("txa_stage");
stage.value = " " + crlf + fr[animate_fr_x];
x++;
if (x >= max)
x = 0;
setTimeout("animate_cheerleader()", 200);
}
</script>
</head>
<body>
<textarea id="txa_stage" rows="4" cols="11" readonly></textarea>
<br />
<input type=button value="Start Animation" onclick="animate_cheerleader()">
</body>
</html>[/html]
Copyright Note
This script is free to use and can be modified as you wish.
Related Links
Javascript Source
About HTML element
About JavaScript




