語法展示:: http://home.graffiti.net/jcgfhjgfch/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="JavaScript1.2">
<!--
message="紫蓮の翼 http://blog.pixnet.net/como0925"
ns6switch=1
var ns6=document.getElementById&&!document.all
mes=new Array();
mes[0]=-2;
mes[1]=-5;
mes[2]=-8;
mes[3]=-11;
mes[4]=-14;
mes[5]=-11;
mes[6]=-8;
mes[7]=-5;
mes[8]=-2;
num=0;
num2=0;
txt="";
function jump0(){
if (ns6&&!ns6switch){
jump.innerHTML=message
return
}
if(message.length > 6){
for(i=0; i != message.length;i++){
txt=txt+"<span style='position:relative;' id='n"+i+"'>"+message.charAt(i)+"</span>"};
jump.innerHTML=txt;
txt="";
jump1a()
}
else{
alert("您輸入的文字太少 !")
}
}
function jump1a(){
nfinal=(document.getElementById)? document.getElementById("n0") : document.all.n0
nfinal.style.left=-num2;
if(num2 != 9){
num2=num2+3;
setTimeout("jump1a()",50)
}
else{
jump1b()
}
}
function jump1b(){
nfinal.style.left=-num2;
if(num2 != 0){num2=num2-3;
setTimeout("jump1b()",50)
}
else{
jump2()
}
}
function jump2(){
txt="";
for(i=0;i != message.length;i++){
if(i+num > -1 && i+num < 70){
txt=txt+"<span style='position:relative;top:"+mes[i+num]+"'>"+message.charAt(i)+"</span>"
}
else{txt=txt+"<span>"+message.charAt(i)+"</span>"}
}
jump.innerHTML=txt;
txt="";
if(num != (-message.length)){
num--;
setTimeout("jump2()",50)}
else{num=0;
setTimeout("jump0()",50)}}
-->
</script>
<div id="jumpx" align="center" style="font-family:細明體;color:#000000;font-size:15pt"></div>
<script language="JavaScript">
<!--
if (document.all||document.getElementById){
jump=(document.getElementById)? document.getElementById("jumpx") : document.all.jumpx
jump0()
}
else
document.write(message)
-->
</script>
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/khghjg/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<DIV id=myText style="TOP:170px;VISIBILITY:hidden;POSITION:absolute">
<font color="#FF0000">Java Script</font> 是一個 <font color="#0000FF">Java Applet</font> 程式語言的簡易版本,它是由 Netscape 與 Sun 這兩家公司在 1995 年底所制定的,早期是為了在 Navigator 2.0上 設計動態網頁而設計的,它部份取自 <font color="#0000FF">Java Applet</font> 的精髓,但並不提供例如 <font color="#0000FF">Java Applet</font> 的類別與繼承的特性。<br><br><font color="#FF0000">Java Script</font> 程式是 HTML 檔案的一部份,放在標籤 <script> 與 </script> 當中,和 <font color="#0000FF">Java Applet</font> 不同的是, <font color="#FF0000">Java Script</font> 是純粹的直譯語言,也因如此,它的功能較單純,必須要搭配 HTML 檔案才能被執行;相反的, <font color="#FF0000">Java Script</font> 程式可以製作成 <font color="#0000FF">Java Applet</font> 來執行。
</DIV>
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language=JavaScript>
<!--
var timerID;
var leftbox;
function myLeftMove() {
if(document.all){
document.all.myText.style.pixelLeft = document.body.offsetWidth;
document.all.myText.style.visibility = "visible";
}
if(document.layers){
document.layers["myText"].left = innerWidth;
document.layers["myText"].visibility = "visible";
}
timerID = window.setInterval("setLeftMv()",100);
}
function setLeftMv() {
if(document.all)document.all.myText.style.pixelLeft -= 10;
if(document.all)leftbox = document.all.myText.style.pixelLeft;
if(document.layers)document.layers["myText"].left -= 10;
if(document.layers)leftbox = document.layers["myText"].left;
if (leftbox<=5) {
if(document.all)document.all.myText.style.pixelLeft = 5;
if(document.layers)document.layers["myText"].left = 5;
window.clearInterval(timerID);
}
}
-->
</script>
將以下程式碼複製,貼在<body >標籤裡面。
onload=myLeftMove()
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/opvcfgx/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="JavaScript1.2">
<!--
var it=0
var head="display:''"
function initialize(){
mytext=typing.innerText
var myheight=typing.offsetHeight
typing.innerText=''
document.all.typing.style.height=myheight
typeit()
}
function typeit(){
typing.insertAdjacentText("beforeEnd",mytext.charAt(it))
if (it<mytext.length-1){
it++
setTimeout("typeit()",100)
}
else
return
}
if (document.all)
document.body.onload=initialize
-->
</script>
<span id="typing" style="visiblity:hidden;height:2" style=&{head};>歡迎光臨紫蓮の翼 http://blog.pixnet.net/como0925</span>
在 setTimeout("typeit()",100) 中修改文字出現的速度 |
自行修改文字訊息的內容 |
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pikfsdr/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript">
<!--
message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925";
colours = new Array('#FF0000','#0000FF','#FF00FF')
siZe = 5;
message = message.split(' ');
timer = null;
clrPos = 0;
msgPos = 0;
jog = 1;
currentStep = 10;
step = 8;
ns = (document.layers)?1:0;
viz = (document.layers)?'hide':'hidden';
if (ns)
document.write("<div id='T' style='position:absolute'></div><br>");
else {
document.write("<div style='position:absolute'>");
document.write("<div align='center' style='position:relative'>");
document.write("<div id='T' style='position:absolute;width:0;height:0;font-family:Arial;font-size:0'>kurt</div>");
document.write("</div></div><br>");
}
function wenchin() {
var pageHeight = (document.layers)?window.innerHeight:window.document.body.offsetHeight;
var pageWidth = (document.layers)?window.innerWidth:window.document.body.offsetWidth;
if (ns) {
ypos = pageHeight / 2;
var Write = '<div align="center" style="width:0px;height:0px;font-family:Arial,Verdana;font-size:'+currentStep/4+'px;color:'+colours[clrPos]+'">'+message[msgPos]+'</div>';
document.T.top = ypos + -currentStep / 8 + window.pageYOffset;
document.T.document.write(Write)
document.T.document.close();
}
else {
ypos = pageHeight / 2;
xpos = pageWidth / 2;
T.style.width = currentStep;
T.style.pixelTop = ypos + -currentStep / 16 + document.body.scrollTop;
T.style.pixelLeft = (xpos - 20)+ -currentStep / 2;
T.style.fontSize = currentStep / 8;
T.innerHTML = message[msgPos];
T.style.color = colours[clrPos];
}
if (ns)step += 5;
else step += 15;
currentStep += step
if (ns) {
if (currentStep > pageWidth) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
else {
if (currentStep > pageWidth * siZe) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
if (msgPos >= message.length) {
clearTimeout(timer);
if (ns) document.T.visibility = viz;
else T.style.visibility = viz;
}
timer = setTimeout("wenchin()",50)
}
-->
</script>
在 message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925"; 中修改文字的內容(假如要換句,以空格隔開) |
在 colours = new Array('#FF0000','#0000FF','#FF00FF') 中修改循環輪替的顏色 |
在 timer = setTimeout("wenchin()",50) 中修改文字顯示的速度 |
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="wenchin()"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pbghjjhg/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="Javascript">
<!--
function init(){
tT="紫蓮の翼 http://blog.pixnet.net/como0925";
sT="紫蓮の翼 http://blog.pixnet.net/como0925";
tF="細明體";"Verdana,Georgia";
sF="細明體";"Verdana,Georgia";
tS=20;
sS=20;
tC="#FF0000";
sC="#3F3F3F";
ea=-8;
mPLS=true;
xan=-0.5;
yan=-0.5;
iT=1;
ie4=document.all?1:0;
ns4=document.layers?1:0;
ns5=(document.getElementById && !document.all)?1:0;
str='';
if (ns5) str+='<div id=gek0 style="position:absolute; z-index:1">';
for(i=1;i<(sS*1.2);i+=iT){
str+='<div id=sha'+i+' style="position:absolute;';
str+='left:'+Math.round(xan*(i+ea)+sS)+'px;';
str+='top:'+Math.round(yan*(i+ea)+i+ea)+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+',800,'+((sS*1.2)-i+iT)+',0)">'+sT+'</div>';
}
if (ns5)
str+='</div><div id=gek1 style="position:absolute;z-index:1"></div>';
str+='<div id=text style="position:absolute;left:'+(sS)+';font-size:'+tS;
str+='px;color:'+tC+';font-family:'+tF+';z-index:2">'+tT+'</div>';
if (ns4) document.main.document.write(str);
if (ie4) document.all.main.innerHTML=str;
if (ns5) document.getElementById("main").innerHTML=str;
if (mPLS){
tog=1;
inc=(iT<3)? 3:iT;
n=new Array(sS*1.2);
for(i=1;i<(sS*1.2);i++){
if (ns5) n[i]=document.getElementById("sha"+i);
if (ie4) n[i]=document.all["sha"+i];
if (ns4) n[i]=document.main.document.layers["sha"+i];
}
sw=(ie4)? document.body.offsetWidth-28:window.innerWidth;
sh=(ie4)? document.body.offsetHeight-20:window.innerHeight;
csw = Math.round(sw/2);
csh = Math.round(sh/2);
if (ns4||ns5){window.captureEvents(Event.MOUSEMOVE); window.onmousemove=mm;}
document.onmousemove=mm;
Ti=setInterval("caSt()",50);
}
}
function mm(e){
if (ns5){
xan=-((e.clientX)-csw)/csw;
yan=-((e.clientY)-csh)/csh;
}
else{
xan=-(((ns4)?e.pageX:event.x)-csw)/csw;
yan=-(((ns4)?e.pageY:event.y)-csh)/csh;
}
}
function caSt(){
if (ns5){ str='';
for(i=1;i<(sS*1.2);i+=inc){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
str+='<div style="position:absolute;left:'+xP+'px;top:'+yP+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+'px,800px,'+((sS*1.2)-i+inc)+'px,0px)">'+sT+'</div>';
}
document.getElementById("gek"+tog).innerHTML=str;
tog=(tog)?0:1;
}else{
for(i=1;i<(sS*1.2);i+=iT){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
if (ie4){
n[i].style.left=xP+"px";
n[i].style.top=yP+"px";}
if (ns4) n[i].moveTo(xP,yP);
}
}
}
-->
</script>
<div id="main" style="position: absolute; width: 100; height: 100; left: 190; top: 190"></div>
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="init()" onUnload="if(Ti)clearInterval(Ti)"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pikfsdr/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript">
<!--
message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925";
colours = new Array('#FF0000','#0000FF','#FF00FF')
siZe = 5;
message = message.split(' ');
timer = null;
clrPos = 0;
msgPos = 0;
jog = 1;
currentStep = 10;
step = 8;
ns = (document.layers)?1:0;
viz = (document.layers)?'hide':'hidden';
if (ns)
document.write("<div id='T' style='position:absolute'></div><br>");
else {
document.write("<div style='position:absolute'>");
document.write("<div align='center' style='position:relative'>");
document.write("<div id='T' style='position:absolute;width:0;height:0;font-family:Arial;font-size:0'>kurt</div>");
document.write("</div></div><br>");
}
function wenchin() {
var pageHeight = (document.layers)?window.innerHeight:window.document.body.offsetHeight;
var pageWidth = (document.layers)?window.innerWidth:window.document.body.offsetWidth;
if (ns) {
ypos = pageHeight / 2;
var Write = '<div align="center" style="width:0px;height:0px;font-family:Arial,Verdana;font-size:'+currentStep/4+'px;color:'+colours[clrPos]+'">'+message[msgPos]+'</div>';
document.T.top = ypos + -currentStep / 8 + window.pageYOffset;
document.T.document.write(Write)
document.T.document.close();
}
else {
ypos = pageHeight / 2;
xpos = pageWidth / 2;
T.style.width = currentStep;
T.style.pixelTop = ypos + -currentStep / 16 + document.body.scrollTop;
T.style.pixelLeft = (xpos - 20)+ -currentStep / 2;
T.style.fontSize = currentStep / 8;
T.innerHTML = message[msgPos];
T.style.color = colours[clrPos];
}
if (ns)step += 5;
else step += 15;
currentStep += step
if (ns) {
if (currentStep > pageWidth) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
else {
if (currentStep > pageWidth * siZe) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
if (msgPos >= message.length) {
clearTimeout(timer);
if (ns) document.T.visibility = viz;
else T.style.visibility = viz;
}
timer = setTimeout("wenchin()",50)
}
-->
</script>
在 message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925"; 中修改文字的內容(假如要換句,以空格隔開) |
在 colours = new Array('#FF0000','#0000FF','#FF00FF') 中修改循環輪替的顏色 |
在 timer = setTimeout("wenchin()",50) 中修改文字顯示的速度 |
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="wenchin()"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pbghjjhg/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="Javascript">
<!--
function init(){
tT="紫蓮の翼 http://blog.pixnet.net/como0925";
sT="紫蓮の翼 http://blog.pixnet.net/como0925";
tF="細明體";"Verdana,Georgia";
sF="細明體";"Verdana,Georgia";
tS=20;
sS=20;
tC="#FF0000";
sC="#3F3F3F";
ea=-8;
mPLS=true;
xan=-0.5;
yan=-0.5;
iT=1;
ie4=document.all?1:0;
ns4=document.layers?1:0;
ns5=(document.getElementById && !document.all)?1:0;
str='';
if (ns5) str+='<div id=gek0 style="position:absolute; z-index:1">';
for(i=1;i<(sS*1.2);i+=iT){
str+='<div id=sha'+i+' style="position:absolute;';
str+='left:'+Math.round(xan*(i+ea)+sS)+'px;';
str+='top:'+Math.round(yan*(i+ea)+i+ea)+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+',800,'+((sS*1.2)-i+iT)+',0)">'+sT+'</div>';
}
if (ns5)
str+='</div><div id=gek1 style="position:absolute;z-index:1"></div>';
str+='<div id=text style="position:absolute;left:'+(sS)+';font-size:'+tS;
str+='px;color:'+tC+';font-family:'+tF+';z-index:2">'+tT+'</div>';
if (ns4) document.main.document.write(str);
if (ie4) document.all.main.innerHTML=str;
if (ns5) document.getElementById("main").innerHTML=str;
if (mPLS){
tog=1;
inc=(iT<3)? 3:iT;
n=new Array(sS*1.2);
for(i=1;i<(sS*1.2);i++){
if (ns5) n[i]=document.getElementById("sha"+i);
if (ie4) n[i]=document.all["sha"+i];
if (ns4) n[i]=document.main.document.layers["sha"+i];
}
sw=(ie4)? document.body.offsetWidth-28:window.innerWidth;
sh=(ie4)? document.body.offsetHeight-20:window.innerHeight;
csw = Math.round(sw/2);
csh = Math.round(sh/2);
if (ns4||ns5){window.captureEvents(Event.MOUSEMOVE); window.onmousemove=mm;}
document.onmousemove=mm;
Ti=setInterval("caSt()",50);
}
}
function mm(e){
if (ns5){
xan=-((e.clientX)-csw)/csw;
yan=-((e.clientY)-csh)/csh;
}
else{
xan=-(((ns4)?e.pageX:event.x)-csw)/csw;
yan=-(((ns4)?e.pageY:event.y)-csh)/csh;
}
}
function caSt(){
if (ns5){ str='';
for(i=1;i<(sS*1.2);i+=inc){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
str+='<div style="position:absolute;left:'+xP+'px;top:'+yP+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+'px,800px,'+((sS*1.2)-i+inc)+'px,0px)">'+sT+'</div>';
}
document.getElementById("gek"+tog).innerHTML=str;
tog=(tog)?0:1;
}else{
for(i=1;i<(sS*1.2);i+=iT){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
if (ie4){
n[i].style.left=xP+"px";
n[i].style.top=yP+"px";}
if (ns4) n[i].moveTo(xP,yP);
}
}
}
-->
</script>
<div id="main" style="position: absolute; width: 100; height: 100; left: 190; top: 190"></div>
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="init()" onUnload="if(Ti)clearInterval(Ti)"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/wsghyt/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript">
<!--
var backgr1="01.jpg"
var backgr2="02.jpg"
var backgr3="03.jpg"
var backgr4="04.jpg"
var backgr5="05.jpg"
var cur=Math.round(6*Math.random())
if (cur<=1)
backgr=backgr1
else if (cur<=4)
backgr=backgr2
else
backgr=backgr3
document.write('<body background="'+backgr+'" bgcolor="#FFEAD5">')
-->
</script>
自行修改圖檔的名稱及路徑 |
在 <body background="'+backgr+'" bgcolor="#FFEAD5"> 中修改圖檔遺失時取代的背景顏色 |
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/gfsfse/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<div id="logo" style="position:absolute; visibility:show; left:0px; top:-150px; z-index:2">
<table border="0" cellspacing="0" cellpadding="0" width=60>
<tr>
<td>
<center>
<a href="JavaScript:void(0)" _fcksavedurl=""JavaScript:void(0)"" onMouseOver="switchLogo('menu')" ;>
<p align="right">選<br>擇<br>背<br>景</p>
</a>
</center>
</td>
</tr>
</table>
</div>
<div id="menu" style="position:absolute; visibility:show; left:0px; top:-150px; z-index:2">
<table border="0" cellspacing="0" cellpadding="0" width=75><tr><td>
<span class=bgimages onClick=tile();event.cancelBubble=true>
<table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td colspan="5" align="center" bgcolor="#FF00FF">
<p align="center">選擇背景</td>
</tr>
<tr>
<td align="center"><img border="0" src="01.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="02.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="03.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="04.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="05.jpg" width="15" height="15"></td>
</tr>
<tr>
<td align="center"><img border="0" src="06.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="07.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="08.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="09.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="10.jpg" width="15" height="15"></td>
</tr>
<tr>
<td align="center"><img border="0" src="11.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="12.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="13.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="14.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="15.jpg" width="15" height="15"></td>
</tr>
<tr>
<td align="center"><img border="0" src="16.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="17.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="18.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="19.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="20.jpg" width="15" height="15"></td>
</tr>
<tr>
<td align="center"><img border="0" src="21.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="22.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="23.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="24.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="25.jpg" width="15" height="15"></td>
</tr>
<tr>
<td align="center"><img border="0" src="26.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="27.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="28.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="29.jpg" width="15" height="15"></td>
<td align="center"><img border="0" src="30.jpg" width="15" height="15"></td>
</tr>
</table></span>
</td></tr></table>
</div>
<script language=JavaScript1.2>
<!--
function tile(){
if (!document.all)
return
var source=event.srcElement
if (source.tagName=="IMG") {
document.body.style.backgroundImage="url("+source.src+")";
document.body.style.color="#FFFF00";
}
}
function restore(){
document.body.style.backgroundImage='';
document.body.style.color='';
}
document.body.onclick=restore
-->
</script>
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language=javaScript>
<!--
function setVariables(){
if (navigator.appName == "Netscape") {
v=".top=";h=".left=";dS="document.";sD="";
y="window.pageYOffset";x="window.pageXOffset";iW="window.innerWidth";iH="window.innerHeight"
}
else {h=".pixelLeft=";v=".pixelTop=";dS="";sD=".style";
y="document.body.scrollTop";x="document.body.scrollLeft";
iW="document.body.clientWidth";iH="document.body.clientHeight"
}
xyz=500
object="logo";
checkLocationA()
}
movex=0,movey=0,xdiff=0,ydiff=0,ystart=0,xstart=0
function checkLocation(){
innerX=eval(iW)-75
innerY=eval(iH)-100
if (document.layers){innerY-=10;innerX-=10}
yy=eval(y);
xx=eval(x);
ydiff=ystart-yy;
xdiff=xstart-xx;
if ((ydiff<(-1))||(ydiff>(1))) movey=Math.round(ydiff/10),ystart-=movey
if ((xdiff<(-1))||(xdiff>(1))) movex=Math.round(xdiff/10),xstart-=movex
eval(dS+object+sD+v+(ystart+innerY));
eval(dS+object+sD+h+(xstart+innerX));
setTimeout("checkLocation()",10)}
function checkLocationA(){ystart=eval(y);xstart=eval(x);}
function switchLogo(abc){
if (abc=="menu"){
eval(dS+object+sD+v+0);
eval(dS+object+sD+h+(-200));
object=abc}
else xyz=setTimeout("delayLogo()",2000)
}
function delayLogo(){
eval(dS+object+sD+v+0);
eval(dS+object+sD+h+(-200));
object='logo'
}
-->
</script>
在 innerX=eval(iW)-75 中修改選單距離視窗右方的距離 |
在 innerY=eval(iH)-100 中修改選單距離視窗下方的距離 |
將以下程式碼複製,貼在<body >標籤裡面。
不要忘記付件也要一起帶回家喔~!!...... >>>>>>我是附件帶我回家<<<<<<<
下載後解壓縮,將圖檔置於網頁同一目錄下
在 width=75 中修改選單的寬度(如無自行增減圖檔不需修改) |
在 bgcolor="#FF00FF" 中修改標題的底色 |
在 document.body.style.color="#FFFF00" 中修改選擇背景後標題的顏色 |
可自行製作更換背景圖檔,預設大小15X15 |
onLoad="setVariables();checkLocation()" style="margin-left: 2; margin-right: 10; margin-top: 2"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/fjrggfdd/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<center>
<script language="JavaScript1.2">
<!--
function tile(){
if (!document.all)
return
var source=event.srcElement
if (source.tagName=="IMG") {
document.body.style.backgroundImage="url("+source.src+")";
}
}
function restore(){
document.body.style.backgroundImage='';
document.body.style.color='';
}
document.body.onclick=restore
-->
</script>
<span class="bgimages" onClick="tile();event.cancelBubble=true">
<img src="01.gif">
<img src="02.gif">
<img src="03.gif">
<img src="04.gif">
<img src="05.gif">
<img src="06.gif">
<img src="07.gif">
<img src="08.gif">
<img src="09.gif">
<img src="10.gif">
</span>
</center>
將以下程式碼複製,貼在<head>及</head>標籤之間。
<style>
<!--
.bgimages img {cursor:hand}
-->
</style>
不要忘記付件也要一起帶回家喔~!!...... >>>>>>我是附件帶我回家<<<<<<<
下載後解壓縮,將圖檔置於網頁同一目錄下
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/khjfcjhgf/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<IMG height=110 id=hand1 src="cdh1.gif" style="DISPLAY: none" width=94>
<IMG height=110 id=hand2 src="cdh2.gif" style="DISPLAY: none" width=94>
<DIV id=MsgText style="DISPLAY:none">
Java Script是一個Java Applet程式語言的簡易版本,它是由Netscape與Sun這兩家公司在1995年底所制定的,早期是為了在Navigator 2.0上設計動態網頁而設計的,它部份取自Java Applet的精髓,但並不提供例如Java Applet的類別與繼承的特性。<br>Java Script程式是HTML檔案的一部份,放在標籤<script>與</script>當中,和Java Applet不同的是,Java Script是純粹的直譯語言,也因如此,它的功能較單純,必須要搭配HTML檔案才能被執行;相反的,Java Script程式可以製作成Java Applet來執行。
</DIV>
<DIV id=MsgArea></DIV>
<script language=VBScript>
<!--
Delay = 50
Txt = MsgText.InnerHtml
CharPos = 0
Msg = ""
ImageTag1="<IMG id=Pen src=" & hand1.src & " style=position:absolute border=0>"
ImageTag2="<IMG id=Pen src=" & hand2.src & " style=position:absolute border=0>"
Sub Window_OnLoad()
Document.Body.Scroll="no"
ShowChar
End Sub
Sub ShowChar()
CharPos=CharPos + 1
If CharPos <= Len(Txt) then
CurrentChar = Mid(Txt,CharPos,1)
If CurrentChar = "<" Then
' Process HTML tags without a delay
Do Until CurrentChar = ">"
Msg = Msg & CurrentChar
CharPos = CharPos + 1
CurrentChar = Mid(Txt, CharPos, 1)
Loop
Msg = Msg & CurrentChar
Else
Msg = Msg & CurrentChar
End If
if CharPos mod 2 = 0 then ImageTag = ImageTag1 else ImageTag = ImageTag2
MsgArea.innerhtml = Msg & ImageTag
document.body.scrollTop=600
d = Delay
If CurrentChar = "、" or CurrentChar = "?" or CurrentChar = "﹗" or CurrentChar = "。"Then d =500
If CurrentChar = "," then d =200
TimerId = Window.SetTimeout("ShowChar",d,"VBScript")
Else
Document.Body.Scroll = "yes"
End If
End Sub
-->
</script>
在 Delay = 50 中修改寫字的速度
不要忘記付件也要一起帶回家喔~!!...... >>>>>>我是附件帶我回家<<<<<<<
下載後解壓縮,將圖檔置於網頁同一目錄下
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/fjfgjghdg/
請用IE6.0或更新版本觀看語法特效展示
訊息魔法師(梅林)為 Windows Me、Windows 2000、Windows XP 預設之精靈,假如您看不到此特效,表示您的系統太過老舊,請自行下載梅林精靈演員檔置於 C:\WINDOWS\msagent\chars 目錄下。
將以下程式碼複製,貼在<body>及</body>標籤之間。
<object id=tsaiannie53441 classid=CLSID:D45FD31B-5C6E-11D1-9EC1-00C04FD7081F></object>
<script language="JavaScript">
<!--
var MerlinID;
var MerlinACS;
tsaiannie53441.Connected = true;
MerlinLoaded = LoadLocalAgent(MerlinID, MerlinACS);
Merlin = tsaiannie53441.Characters.Character(MerlinID);
Merlin.Show();
Merlin.Play("Surprised");
Merlin.Speak("歡呼");
Merlin.Play("GestureLeft");
Merlin.Speak("介紹左方");
Merlin.Play("GestureRight");
Merlin.Speak("介紹右方");
Merlin.Play("Pleased");
Merlin.Speak("拱手作揖");
Merlin.Play("GestureDown");
Merlin.Speak("小鞠躬");
Merlin.Play("Greet");
Merlin.Speak("大鞠躬");
Merlin.Play("Suggest");
Merlin.Speak("靈機一動");
Merlin.Play("Think");
Merlin.Speak("點一下廣告吧");
Merlin.MoveTo(400,300);
Merlin.Hide();
function LoadLocalAgent(CharID, CharACS) {
LoadReq = tsaiannie53441.Characters.Load(CharID, CharACS);
return(true);
}
-->
</script>
在 Merlin.Speak("歡呼"); 中修改訊息的內容 |
在 Merlin.Play("Surprised"); 中修改配合的動作 |
動作指令一覽表 | 動作 | 指令 | 離開 | Merlin.Hide(); | 移動 | Merlin.MoveTo(400,300); | 點頭 | Merlin.Play("Acknowledge"); | 瞪眼握拳 | Merlin.Play("Alert"); | 吹喇叭 | Merlin.Play("Announce"); | 眨眼睛 | Merlin.Play("Blink"); | 傷腦筋 | Merlin.Play("Confused"); | 拿出獎盃 | Merlin.Play("Congratulate"); | 拍拍手 | Merlin.Play("Congratulate_2"); | 一臉無辜 | Merlin.Play("Decline"); | 施魔法1 | Merlin.Play("DoMagic1"); | 施魔法2 | Merlin.Play("DoMagic2"); | 仔細聆聽左方 | Merlin.Play("DontRecognize"); | 攤開雙手 | Merlin.Play("Explain"); | 小鞠躬 | Merlin.Play("GestureDown"); | 介紹左方 | Merlin.Play("GestureLeft"); | 介紹右方 | Merlin.Play("GestureRight"); | 雙手高舉 | Merlin.Play("GestureUp"); | 慢慢敲門 | Merlin.Play("GetAttention"); | 快速敲門 | Merlin.Play("GetAttentionContinued"); | 快速無聲敲門 | Merlin.Play("GetAttentionReturn"); | 大鞠躬 | Merlin.Play("Greet"); | 豎起雙耳 | Merlin.Play("Hearing_1"); | 聽聽左邊 | Merlin.Play("Hearing_2"); | 豎起右耳 | Merlin.Play("Hearing_3"); | 豎起左耳 | Merlin.Play("Hearing_4"); | 暫離 | Merlin.Play("Hide"); | 看上方 | Merlin.Play("Idle1_1"); | 看左邊 | Merlin.Play("Idle1_2"); | 看右邊 | Merlin.Play("Idle1_3"); | 看右上方 | Merlin.Play("Idle1_4"); | 拿出魔法棒 | Merlin.Play("Idle2_1"); | 歡迎光臨 | Merlin.Play("Idle2_2"); | 大笑 | Merlin.Play("Idle3_1"); | 打瞌睡 | Merlin.Play("Idle3_2"); | 慢慢看下方 | Merlin.Play("LookDown"); | 看下方 | Merlin.Play("LookDownBlink"); | 看上方 | Merlin.Play("LookDownReturn"); | 慢慢看左上方 | Merlin.Play("LookLeft"); | 快速看左上方 | Merlin.Play("LookLeftBlink"); | 看左上方後恢復 | Merlin.Play("LookLeftReturn"); | 慢慢看右上方 | Merlin.Play("LookRight"); | 快速看右上方 | Merlin.Play("LookRightBlink"); | 看右上方後恢復 | Merlin.Play("LookRightReturn"); | 慢慢看上方 | Merlin.Play("LookUp"); | 快速看上方 | Merlin.Play("LookUpBlink"); | 看上方後恢復 | Merlin.Play("LookUpReturn"); | 向下飛 | Merlin.Play("MoveDown"); | 向右飛 | Merlin.Play("MoveLeft"); | 向左飛 | Merlin.Play("MoveRight"); | 向上飛 | Merlin.Play("MoveUp"); | 拱手作揖 | Merlin.Play("Pleased"); | 煮藥後收回 | Merlin.Play("Process"); | 煮藥 | Merlin.Play("Processing"); | 查閱資料 | Merlin.Play("Read"); | 查到資料 | Merlin.Play("ReadContinued"); | 反覆看書 | Merlin.Play("Reading"); | 收起書本 | Merlin.Play("ReadReturn"); | 嘆氣 | Merlin.Play("Sad"); | 看水晶球後收回 | Merlin.Play("Search"); | 看水晶球 | Merlin.Play("Searching"); | 出現2 | Merlin.Play("Show"); | 仔細聆聽左方2 | Merlin.Play("StartListening"); | 摀起雙耳 | Merlin.Play("StopListening"); | 靈機一動 | Merlin.Play("Suggest"); | 歡呼 | Merlin.Play("Surprised"); | 想事情 | Merlin.Play("Think"); | 摸鬍子 | Merlin.Play("Thinking"); | 身體向前傾 | Merlin.Play("Uncertain"); | 揮揮手 | Merlin.Play("Wave"); | 寫字一遍 | Merlin.Play("Write"); | 寫字兩遍 | Merlin.Play("WriteContinued"); | 收起書筆 | Merlin.Play("WriteReturn"); | 反覆寫字 | Merlin.Play("Writing"); | 出現 | Merlin.Show(); |
|
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/tghyujkgf/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript1.2">
<!--
var thecontent='<b><font color="#FF8000" face="細明體" size="3">紫蓮の翼 http://blog.pixnet.net/como0925</font></b>'
var hidetimer='';
var BallSpeed = 2;
var contentWidth;
var contentHeight;
var maxBallSpeed = 50;
var xMax;
var yMax;
var xPos = 0;
var yPos = 0;
var xDir = 'right';
var yDir = 'down';
var superballRunning = true;
var tempBallSpeed;
var currentBallSrc;
var newXDir;
var newYDir;
function initializeBall() {
if (document.all) {
xMax = document.body.clientWidth
yMax = document.body.clientHeight
document.all("supertext").style.visibility = "visible";
contentWidth=supertext.offsetWidth
contentHeight=supertext.offsetHeight
}
else if (document.layers) {
xMax = window.innerWidth;
yMax = window.innerHeight;
contentWidth=document.supertext.document.width
contentHeight=document.supertext.document.height
document.layers["supertext"].visibility = "show";
}
setTimeout('moveBall()',400);
if (hidetimer!='')
setTimeout("hidetext()",hidetimer)
}
function moveBall() {
if (superballRunning == true) {
calculatePosition();
if (document.all) {
document.all("supertext").style.left = xPos + document.body.scrollLeft;
document.all("supertext").style.top = yPos + document.body.scrollTop;
}
else if (document.layers) {
document.layers["supertext"].left = xPos + pageXOffset;
document.layers["supertext"].top = yPos + pageYOffset;
}
animatetext=setTimeout('moveBall()',20);
}
}
function calculatePosition() {
if (xDir == "right") {
if (xPos > (xMax - contentWidth - BallSpeed)) {
xDir = "left";
}
}
else if (xDir == "left") {
if (xPos < (0 + BallSpeed)) {
xDir = "right";
}
}
if (yDir == "down") {
if (yPos > (yMax - contentHeight - BallSpeed)) {
yDir = "up";
}
}
else if (yDir == "up") {
if (yPos < (0 + BallSpeed)) {
yDir = "down";
}
}
if (xDir == "right") {
xPos = xPos + BallSpeed;
}
else if (xDir == "left") {
xPos = xPos - BallSpeed;
}
else {
xPos = xPos;
}
if (yDir == "down") {
yPos = yPos + BallSpeed;
}
else if (yDir == "up") {
yPos = yPos - BallSpeed;
}
else {
yPos = yPos;
}
}
function hidetext(){
if (document.all)
supertext.style.visibility="hidden"
else if (document.layers)
document.supertext.visibility="hide"
clearTimeout(animatetext)
}
if (document.all||document.layers){
document.write('<span id="supertext"><nobr>'+thecontent+'</nobr></span>')
window.onload = initializeBall;
window.onresize = new Function("window.location.reload()");
}
-->
</script>
<style type="text/css">
<!--
#supertext {
position:absolute;
left:0;
top:0;
visibility:hide;
visidility:hidden;
}
-->
</style>
在 var thecontent='<b><font color="#FF8000" face="細明體" size="3">紫蓮の翼 http://blog.pixnet.net/como0925</font></b>' 中修改文字的內容、粗細、字體、大小、顏色 |
在 var BallSpeed = 2; 中修改飄移的速度 |
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/iuklhjgh/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="JavaScript">
<!--
var message='<center><font face="細明體" color="#FF0000" size="4">紫蓮の翼 http://blog.pixnet.net/como0925</font></center>';
var backgroundcolor="#FFFF00";
var displaymode=0;
var displayduration=10000;
var flashmode=1;
var flashtocolor="#00FF00";
-->
</script>
<script language="JavaScript">
<!--
function regenerate(){
window.location.reload()
}
var which=0
function regenerate2(){
if (document.layers)
setTimeout("window.onresize=regenerate",400)
}
function display2(){
if (document.layers){
if (topmsg.visibility=="show")
topmsg.visibility="hide"
else
topmsg.visibility="show"
}
else if (document.all){
if (topmsg.style.visibility=="visible")
topmsg.style.visibility="hidden"
else
topmsg.style.visibility="visible"
setTimeout("display2()",Math.round(Math.random()*10000)+10000)
}
}
function flash(){
if (which==0){
if (document.layers)
topmsg.bgColor=flashtocolor
else
topmsg.style.backgroundColor=flashtocolor
which=1
}
else{
if (document.layers)
topmsg.bgColor=backgroundcolor
else
topmsg.style.backgroundColor=backgroundcolor
which=0
}
}
if (document.all){
document.write('<span id="topmsg" style="position:absolute;visibility:hidden">'+message+'</span>')
}
function logoit(){
document.all.topmsg.style.left=document.body.scrollLeft+document.body.clientWidth/2-document.all.topmsg.offsetWidth/2
document.all.topmsg.style.top=document.body.scrollTop+document.body.clientHeight-document.all.topmsg.offsetHeight-4
}
function logoit2(){
topmsg.left=pageXOffset+window.innerWidth/2-topmsg.document.width/2
topmsg.top=pageYOffset+window.innerHeight-topmsg.document.height-5
setTimeout("logoit2()",90)
}
function setmessage(){
document.all.topmsg.style.left=document.body.scrollLeft+document.body.clientWidth/2-document.all.topmsg.offsetWidth/2
document.all.topmsg.style.top=document.body.scrollTop+document.body.clientHeight-document.all.topmsg.offsetHeight-4
document.all.topmsg.style.backgroundColor=backgroundcolor
document.all.topmsg.style.visibility="visible"
if (displaymode==1)
setTimeout("topmsg.style.visibility='hidden'",displayduration)
else if (displaymode==2)
display2()
if (flashmode==1)
setInterval("flash()",1000)
window.onscroll=logoit
window.onresize=new Function("window.location.reload()")
}
function setmessage2(){
topmsg=new Layer(window.innerWidth)
topmsg.bgColor=backgroundcolor
regenerate2()
topmsg.document.write(message)
topmsg.document.close()
logoit2()
topmsg.visibility="show"
if (displaymode==1)
setTimeout("topmsg.visibility='hide'",displayduration)
else if (displaymode==2)
display2()
if (flashmode==1)
setInterval("flash()",1000)
}
if (document.layers)
window.onload=setmessage2
else if (document.all)
window.onload=setmessage
-->
</script>
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/edsfghyt/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<div style="position:absolute;top:1;display:none;font:bold italic 20pt Verdana;color:#FF0000;" align="right">紫蓮の翼 http://blog.pixnet.net/como0925</div>
<script language="JavaScript">
<!--
var IW= 0;
var IH= 0;
var PX= 0;
var PY= 0;
var ZIN= 0;
var us= null;
var IMGW= 35;
var IMGH= 95;
var LSAFETY= 0;
var TSAFETY= 0;
function marking()
{
if (navigator.appVersion.indexOf("Mac") == -1)
{
oldIW= IW;
oldIH= IH;
oldPX= PX;
oldPY= PY;
if ((document.body.clientHeight != oldIH)||(document.body.clientWidth != oldIW)||(document.body.scrollLeft != oldPX)||(document.body.scrollTop != oldPY)) {
alldivs= document.all.tags("DIV");
if (us == null){
for (i=0; i<alldivs.length; i++)
{
us= alldivs(i);
}
}
if(window != window.top){
var ourDoc= "";
var ourDocWidth= 0;
var ourDocHeight= 0;
var ourDocTest= 0;
for(i=0;i<window.top.frames.length; i++){
if((window.top.frames[i].document.body.clientWidth * window.top.frames[i].document.body.clientHeight)>ourDocTest)
{
ourDoc= window.top.frames[i];
ourDocTest= window.top.frames[i].document.body.clientWidth * window.top.frames[i].document.body.clientHeight;
}
}
}
if((ourDoc)&&(ourDoc != self)){
us.style.display= "none";
}
if(((ourDoc)&&(ourDoc == self))||(!ourDoc)){
if (us != null){
us.style.display= "none";
IH= document.body.clientHeight;
IW= document.body.clientWidth;
PX= document.body.scrollLeft;
PY= document.body.scrollTop;
us.style.top= (IH+PY-(IMGH+TSAFETY));
us.style.left=(IW+PX-(IMGW+LSAFETY));
for (i=0; i<alldivs.length; i++){
templay= alldivs(i);
if (templay.style.zIndex > ZIN)
us.style.zindex= (templay.style.zIndex + 1);
}
us.onmouseover= neat_mouseover;
us.onmouseout= neat_mouseout;
us.style.display= "";
}
}
}
}
}
function neat_mouseover(){
if(us != null){
window.status="additional text goes here";
return true;
}
}
function neat_mouseout(){
if(us != null){
window.status="";
return true;
}
}
setInterval("marking()",100);
-->
</script>
在 font:bold italic 20pt Verdana; 中修改文字的大小 |
在 color:#FF0000; 中修改文字的顏色 |
自行修改顯示的文字 |
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/fjdyhdfgd/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="JavaScript">
<!--
for (i=0;i<=numberofletters;i++) {
document.write("<span id='span"+i+"' style='position:absolute'></span>")
document.close()
}
-->
</script>
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript">
<!--
var your_message="歡迎光臨紫蓮の翼http://blog.pixnet.net/como0925"
var textfont="細明體"
var textsize="9"
var textcolor="#FF0000"
var textboldness=0
var tempo=250
var stepx=45
var stepy=25
var msg=new Array()
var msg=your_message
var message=msg.split("")
var numberofletters=msg.length-1
var x,y
var marginbottom
var marginleft=0
var margintop=0
var marginright
textboldness=textboldness*100
var timer
var xpos=new Array()
var ypos=new Array()
var spancontent=new Array()
for (i=0; i<=numberofletters;i++) {
xpos[i]=0
ypos[i]=0
}
for (i=0;i<=numberofletters;i++) {
spancontent[i]="<span style='position:relative;font-family:"+textfont+";font-size:"+textsize+"pt;color:"+textcolor+";font-weight:"+textboldness+"'>"+message[i]+"</span>"
}
function setValues() {
var firsttimer= setTimeout("setValues2()",1000)
}
function setValues2() {
if (document.all) {
marginbottom = document.body.clientHeight-0
marginright = document.body.clientWidth-55
for (i=0;i<=numberofletters;i++) {
var thisspan = eval("document.all.span"+i)
thisspan.innerHTML=spancontent[i]
var thisspan = eval("document.all.span"+(i)+".style")
thisspan.posLeft=0
thisspan.postop=0
}
moveball()
}
if (document.layers) {
marginbottom = window.innerHeight
marginright = window.innerWidth
for (i=0;i<=numberofletters;i++) {
var thisspan=eval("document.span"+i+".document")
thisspan.write(spancontent[i])
thisspan.close()
var thisspan=eval("document.span"+i)
thisspan.left=0
thisspan.top=0
}
moveball()
}
}
function randommaker(range) {
rand=Math.floor(range*Math.random())
return rand
}
function moveball() {
if (document.all) {
checkposition()
makesnake()
document.all.span0.style.posTop+=stepy
timer=setTimeout("moveball()",tempo)
}
if (document.layers) {
checkposition()
makesnake()
document.span0.top+=stepy
timer=setTimeout("moveball()",tempo)
}
}
function makesnake() {
for (i=numberofletters; i>=1; i--) {
xpos[i]=xpos[i-1]
ypos[i]=ypos[i-1]
}
if (document.all) {
xpos[0]=document.all.span0.style.posLeft+stepx
ypos[0]=document.all.span0.style.posTop+stepy
for (i=0;i<=numberofletters;i++) {
var thisspan=eval("document.all.span"+(i)+".style")
thisspan.posLeft=xpos[i]
thisspan.posTop=ypos[i]
}
}
if (document.layers) {
xpos[0]=document.span0.left+stepx
ypos[0]=document.span0.top+stepy
for (i=0;i<=numberofletters;i++) {
var thisspan = eval("document.span"+i)
thisspan.left=xpos[i]
thisspan.top=ypos[i]
}
}
}
function checkposition() {
if (document.all) {
if (document.all.span0.style.posLeft>marginright) {
stepx=(stepx+randommaker(2))*-1
document.all.span0.style.posLeft-=1
}
if (document.all.span0.style.posLeft<marginleft) {
stepx=(stepx+randommaker(2))*-1
document.all.span0.style.posLeft+=1
}
if (document.all.span0.style.posTop>marginbottom) {
stepy=(stepy+randommaker(2))*-1
document.all.span0.style.posTop-=1
}
if (document.all.span0.style.posTop<margintop) {
stepy=(stepy+randommaker(2))*-1
document.all.span0.style.posTop+=1
}
}
if (document.layers) {
if (document.span0.left>=marginright) {
stepx=(stepx+randommaker(2))*-1
document.span0.left-=10
}
if (document.span0.left<=marginleft) {
stepx=(stepx+randommaker(2))*-1
document.span0.left+=10
}
if (document.span0.top>=marginbottom) {
stepy=(stepy+randommaker(2))*-1
document.span0.top-=10
}
if (document.span0.top<=margintop) {
stepy=(stepy+randommaker(2))*-1
document.span0.top+=10
}
}
}
-->
</script>
在 var your_message="歡迎光臨紫蓮の翼http://blog.pixnet.net/como0925" 中修改文字的內容 |
在 var textfont="細明體" 中修改文字的字體 |
在 var textsize="9" 中修改文字的大小 |
在 var textcolor="#FF0000" 中修改文字的顏色 |
在 var textboldness=0 中修改文字的邊緣大小 |
在 var tempo=250 中修改特效的速度 |
在 var stepx=45 中修改發射的角度 |
在 var stepy=25 中修改反彈的角度 |
在 ("setValues2()",1000) 中修改特效執行前等候的時間(每1秒=1000) |
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="setValues()"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pbghjjhg/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<script language="Javascript">
<!--
function init(){
tT="紫蓮の翼 http://blog.pixnet.net/como0925";
sT="紫蓮の翼 http://blog.pixnet.net/como0925";
tF="細明體";"Verdana,Georgia";
sF="細明體";"Verdana,Georgia";
tS=20;
sS=20;
tC="#FF0000";
sC="#3F3F3F";
ea=-8;
mPLS=true;
xan=-0.5;
yan=-0.5;
iT=1;
ie4=document.all?1:0;
ns4=document.layers?1:0;
ns5=(document.getElementById && !document.all)?1:0;
str='';
if (ns5) str+='<div id=gek0 style="position:absolute; z-index:1">';
for(i=1;i<(sS*1.2);i+=iT){
str+='<div id=sha'+i+' style="position:absolute;';
str+='left:'+Math.round(xan*(i+ea)+sS)+'px;';
str+='top:'+Math.round(yan*(i+ea)+i+ea)+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+',800,'+((sS*1.2)-i+iT)+',0)">'+sT+'</div>';
}
if (ns5)
str+='</div><div id=gek1 style="position:absolute;z-index:1"></div>';
str+='<div id=text style="position:absolute;left:'+(sS)+';font-size:'+tS;
str+='px;color:'+tC+';font-family:'+tF+';z-index:2">'+tT+'</div>';
if (ns4) document.main.document.write(str);
if (ie4) document.all.main.innerHTML=str;
if (ns5) document.getElementById("main").innerHTML=str;
if (mPLS){
tog=1;
inc=(iT<3)? 3:iT;
n=new Array(sS*1.2);
for(i=1;i<(sS*1.2);i++){
if (ns5) n[i]=document.getElementById("sha"+i);
if (ie4) n[i]=document.all["sha"+i];
if (ns4) n[i]=document.main.document.layers["sha"+i];
}
sw=(ie4)? document.body.offsetWidth-28:window.innerWidth;
sh=(ie4)? document.body.offsetHeight-20:window.innerHeight;
csw = Math.round(sw/2);
csh = Math.round(sh/2);
if (ns4||ns5){window.captureEvents(Event.MOUSEMOVE); window.onmousemove=mm;}
document.onmousemove=mm;
Ti=setInterval("caSt()",50);
}
}
function mm(e){
if (ns5){
xan=-((e.clientX)-csw)/csw;
yan=-((e.clientY)-csh)/csh;
}
else{
xan=-(((ns4)?e.pageX:event.x)-csw)/csw;
yan=-(((ns4)?e.pageY:event.y)-csh)/csh;
}
}
function caSt(){
if (ns5){ str='';
for(i=1;i<(sS*1.2);i+=inc){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
str+='<div style="position:absolute;left:'+xP+'px;top:'+yP+'px;';
str+='font-family:'+sF+';font-size:'+sS+'px;color:'+sC+';';
str+='clip:rect('+((sS*1.2)-i)+'px,800px,'+((sS*1.2)-i+inc)+'px,0px)">'+sT+'</div>';
}
document.getElementById("gek"+tog).innerHTML=str;
tog=(tog)?0:1;
}else{
for(i=1;i<(sS*1.2);i+=iT){
xP=Math.round(xan*(i+ea)+sS);
yP=Math.round(yan*(i+ea)+i+ea);
if (ie4){
n[i].style.left=xP+"px";
n[i].style.top=yP+"px";}
if (ns4) n[i].moveTo(xP,yP);
}
}
}
-->
</script>
<div id="main" style="position: absolute; width: 100; height: 100; left: 190; top: 190"></div>
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="init()" onUnload="if(Ti)clearInterval(Ti)"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/pikfsdr/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<head>及</head>標籤之間。
<script language="JavaScript">
<!--
message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925";
colours = new Array('#FF0000','#0000FF','#FF00FF')
siZe = 5;
message = message.split(' ');
timer = null;
clrPos = 0;
msgPos = 0;
jog = 1;
currentStep = 10;
step = 8;
ns = (document.layers)?1:0;
viz = (document.layers)?'hide':'hidden';
if (ns)
document.write("<div id='T' style='position:absolute'></div><br>");
else {
document.write("<div style='position:absolute'>");
document.write("<div align='center' style='position:relative'>");
document.write("<div id='T' style='position:absolute;width:0;height:0;font-family:Arial;font-size:0'>kurt</div>");
document.write("</div></div><br>");
}
function wenchin() {
var pageHeight = (document.layers)?window.innerHeight:window.document.body.offsetHeight;
var pageWidth = (document.layers)?window.innerWidth:window.document.body.offsetWidth;
if (ns) {
ypos = pageHeight / 2;
var Write = '<div align="center" style="width:0px;height:0px;font-family:Arial,Verdana;font-size:'+currentStep/4+'px;color:'+colours[clrPos]+'">'+message[msgPos]+'</div>';
document.T.top = ypos + -currentStep / 8 + window.pageYOffset;
document.T.document.write(Write)
document.T.document.close();
}
else {
ypos = pageHeight / 2;
xpos = pageWidth / 2;
T.style.width = currentStep;
T.style.pixelTop = ypos + -currentStep / 16 + document.body.scrollTop;
T.style.pixelLeft = (xpos - 20)+ -currentStep / 2;
T.style.fontSize = currentStep / 8;
T.innerHTML = message[msgPos];
T.style.color = colours[clrPos];
}
if (ns)step += 5;
else step += 15;
currentStep += step
if (ns) {
if (currentStep > pageWidth) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
else {
if (currentStep > pageWidth * siZe) {
currentStep = 10;
step = 8;
msgPos += jog;
clrPos += jog;
}
if (clrPos >= colours.length) clrPos = 0;
}
if (msgPos >= message.length) {
clearTimeout(timer);
if (ns) document.T.visibility = viz;
else T.style.visibility = viz;
}
timer = setTimeout("wenchin()",50)
}
-->
</script>
在 message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925"; 中修改文字的內容(假如要換句,以空格隔開) |
在 colours = new Array('#FF0000','#0000FF','#FF00FF') 中修改循環輪替的顏色 |
在 timer = setTimeout("wenchin()",50) 中修改文字顯示的速度 |
將以下程式碼複製,貼在<body >標籤裡面。
onLoad="wenchin()"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/bngfxfghb/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<div style="position:absolute;top:160;left:100" id="test"></div>
<script language="JavaScript">
<!--
var themessage="歡迎光臨紫蓮の翼 http://blog.pixnet.net/como0925"
var fontsize=10
var appearfor=5000
function position_at_top(){
if (document.layers)
document.test.top=pageYOffset
else if (document.all){
test.innerHTML='<div align=center><font face="Arial">'+themessage+'</font></div>'
setTimeout("test.style.top=160",100)
}
}
function expand(){
if (document.layers){
document.test.document.write('<div align=center style="font-size:'+fontsize+'px"><font face="Arial">'+themessage+'</font></div>')
document.test.document.close()
}
else if (document.all)
test.style.fontSize=fontsize+'px'
fontsize+=5
if (fontsize>45)
{
if (document.layers)
setTimeout("document.test.visibility='hide'",appearfor)
else if (document.all)
setTimeout("test.style.visibility='hidden'",appearfor)
return
}
else
setTimeout("expand()",50)
}
-->
</script>
在 var themessage="歡迎光臨紫蓮の翼 http://blog.pixnet.net/como0925" 中修改訊息的文字 |
在 <div style="position:absolute;top:160;left:100" id="test"></div> 中修改出現時的位置 |
在 var appearfor=5000 中修改文字出現後停留的時間(每1秒=1000) |
在 setTimeout("test.style.top=160",100) 中修改特效執行時的位置 |
在 if (fontsize>45) 中修改最大時文字的大小 |
將以下程式碼複製,貼在<body >標籤裡面。
onload="position_at_top();expand()"
uuiop6623 發表在 痞客邦 留言(0) 人氣()
語法展示:: http://home.graffiti.net/gcjfdghfd/
請用IE6.0或更新版本觀看語法特效展示
將以下程式碼複製,貼在<body>及</body>標籤之間。
<center><font face="細明體" color="#BF80FF" size="2"><span id="fly"></span></font></center>
<script language="JavaScript">
<!--
window.onerror=new Function("return true")
message = "歡迎光臨 紫蓮の翼 http://blog.pixnet.net/como0925"
distance = 350
speed = 200
if (!document.all)
-->
</script>
<script language="JavaScript1.2">
<!--
txt="";num=0;num4=0;flyofle="";flyofwi="";flyofto=""
function stfly(){for(i=0;i != message.length;i++){if(message.charAt(i) != "$"){txt=txt+"<span style='position:relative;visibility:hidden;' id='n"+i+"'>"+message.charAt(i)+"<\/span>"};else{txt=txt+"<br>"}};fly.innerHTML=txt;txt="";flyofle=fly.offsetLeft;flyofwi=fly.offsetWidth;flyofto=fly.offsetTop;fly2b()}
function fly2b(){if(num4 != message.length){if(message.charAt(num4) != "$"){eval("n"+num4+".style.left=flyofle-n"+num4+".offsetLeft+flyofwi/2");eval("n"+num4+".style.top=flyofto-n"+num4+".offsetTop+distance");eval("fly3('n"+num4+"',eval(n"+num4+".style.left.substring(0,n"+num4+".style.left.length-2)),(eval(n"+num4+".style.left.substring(0,n"+num4+".style.left.length-2))/5),eval(n"+num4+".style.top.substring(0,n"+num4+".style.top.length-2)),(eval(n"+num4+".style.top.substring(0,n"+num4+".style.top.length-2))/5))")};num4++;setTimeout("fly2b()",speed)}}
function fly3(target,lef2,num2,top2,num3){if((Math.floor(top2) != 0 && Math.floor(top2) != -1) || (Math.floor(lef2) != 0 && Math.floor(lef2) != -1)){if(eval("'"+lef2+"'").charAt(0) != '-'){lef2=lef2-num2};else{lef2=lef2+(-num2)};if(Math.floor(lef2) != -1){eval(target+".style.visibility='visible';"+target+".style.left=Math.floor(lef2)")};else{eval(target+".style.visibility='visible';"+target+".style.left=Math.floor(lef2+1)")};if(eval("'"+lef2+"'").charAt(0) != '-'){top2=top2-num3};else{top2=top2+(-num3)};if(Math.floor(top2) != -1){eval(target+".style.top=Math.floor(top2)")};else{eval(target+".style.top=Math.floor(top2+1)")};setTimeout("fly3('"+target+"',"+lef2+","+num2+","+top2+","+num3+")",50)}};
stfly()
-->
</script>
uuiop6623 發表在 痞客邦 留言(0) 人氣()