Fri

20

Mar

2009

120、检测QQ在线状况

120、检测QQ在线状况

脚本说明:

把如下代码加入<body>区域中

<script language=vbscript>

Function GetURL(url)

Set Retrieval = CreateObject("Microsoft.XMLHTTP")

With Retrieval

.Open "GET", url, False, "", ""

.Send

GetURL = .ResponseText

End With

Set Retrieval = Nothing

End Function

</script>

小图标:

<script language=vbscript>

Dim T,Start,Length,PicURL

T=GetURL("http://search.tencent.com/cgi-bin/friend/oicq_find?oicq_no=5073937")

Start=Instr(1,T,"ShowResult("+chr(34))

Start=Instr(Start,T,"http://")

Length=Instr(Start,T,chr(34)+","+chr(34))-Start

PicURL=Mid(T,Start,Length)

'document.write "<img src='"&PicURL&"'>"

document.write "<a href=http://search.tencent.com/cgi-bin/friend/user_show_info?ln=37146743 target=_blank title=QQ:37146743><img src="&PicURL&" width=16 height=16 border=0></a>"

</script>

<br>

大图标:

<script language=vbscript>

Dim T,Start,Length,PicURL

T=GetURL("http://search.tencent.com/cgi-bin/friend/user_show_info?ln=37146743")

Start=Instr(1,T,"img height=32")

Start=Instr(Start,T,"http://")

Length=Instr(Start,T,chr(34)+" width=32")-Start

PicURL=Mid(T,Start,Length)

'document.write "<img src='"&PicURL&"'>"

document.write "<a href=http://search.tencent.com/cgi-bin/friend/user_show_info?ln=5073937 target=_blank title=QQ:5073937><img src="&PicURL&" width=32 height=32 border=0></a>"

</script>

 

0 Comments

Fri

20

Mar

2009

119、特殊文字的制作

119、特殊文字的制作

脚本说明:

第一步:把如下代码加入<body>区域中

<SCRIPT>d=document;wr='write';v=void 0;u='';sn='<span style="background-color:#00ff00;color:black;">';sa='</span>';function di(x,y){for(i=1;i<x;i++)d[wr](y);}d.layers?n4=1:n4=0;d.all?i4=1:i4=0;i4&&navigator.platform.indexOf('Mac')!=-1?i4=0:v;fn='font-family:Courier;font-size:12px;';!n4?vb='.g{background-color:black;border-color:green;border-style:solid;border-width:1px;color:#00ff00;'+fn+'}.h{background-color:#00FF00;border:none;color:black;'+fn+'}':vb=u;di(2,'<style>'+vb+'body{'+fn+'}<\/style>');el='elements';vl='value';ih='innerHTML';sp=' ';br='<br>';a1='15';a2='1234';a3='12345';a4='234';a5='2345';a6='1';a7='3';a8='5';a9='135';b0='24';b1='23';b2='2';b3='14';b4='123';b5='4';b6='34';b7='235';f=new Array();f['A']=[a4,a1,a1,a3,a1,a1,a1];f['B']=[a2,a1,a1,a2,a1,a1,a2];f['C']=[a5,a6,a6,a6,a6,a6,a5];f['D']=[a2,a1,a1,a1,a1,a1,a2];f['E']=[a3,a6,a6,a2,a6,a6,a3];f['F']=[a3,a6,a6,a2,a6,a6,a6];f['G']=[a5,a6,a6,'1345',a1,a1,a5];f['H']=[a1,a1,a1,a3,a1,a1,a1];f['I']=[a3,a7,a7,a7,a7,a7,a3];f['J']=[a5,a8,a8,a8,a1,a1,a4];f['K']=[a1,b3,'13','12','13',b3,a1];f['L']=[a6,a6,a6,a6,a6,a6,a3];f['M']=[a1,'1245',a9,a1,a1,a1,a1];f['N']=[a1,a1,'125',a9,'145',a1,a1];f['O']=[a4,a1,a1,a1,a1,a1,a4];f['P']=[a2,a1,a1,a2,a6,a6,a6];f['Q']=[a4,a1,a1,a1,a9,b3,b7];f['R']=[a2,a1,a1,a2,'13',b3,a1];f['S']=[a5,a6,a6,a4,a8,a8,a2];f['T']=[a3,a7,a7,a7,a7,a7,a7];f['U']=[a1,a1,a1,a1,a1,a1,a4];f['V']=[a1,a1,a1,a1,a1,b0,a7];f['W']=[a1,a1,a9,a9,a9,a9,b0];f['X']=[a1,a1,b0,a7,b0,a1,a1];f['Y']=[a1,a1,b0,a7,a7,a7,a7];f['Z']=[a3,a8,b5,a7,b2,a6,a3];f['a']=[u,u,a4,a8,a5,a1,a5];f['b']=[a6,a6,a2,a1,a1,a1,a2];f['c']=[u,u,a5,a6,a6,a6,a5];f['d']=[a8,a8,a5,a1,a1,a1,a5];f['e']=[u,u,a4,a1,a3,a6,a5];f['f']=['345',b2,a3,b2,b2,b2,b2];f['g']=[u,u,a5,a1,a5,a8,a4];f['h']=[a6,a6,a2,a1,a1,a1,a1];f['i']=[a7,u,b4,a7,a7,a7,a3];f['j']=[a8,u,a8,a8,a8,a1,a4];f['k']=[a6,a6,a1,b3,b4,b3,a1];f['l']=[b4,a7,a7,a7,a7,a7,a3];f['m']=[u,u,b0,a9,a9,a9,a9];f['n']=[u,u,a4,a1,a1,a1,a1];f['o']=[u,u,a4,a1,a1,a1,a4];f['p']=[u,u,a2,a1,a2,a6,a6];f['q']=[u,u,a5,a1,a5,a8,a8];f['r']=[u,u,a4,a1,a6,a6,a6];f['s']=[u,u,a5,a6,a4,a8,a2];f['t']=[u,b2,a3,b2,b2,b2,'345'];f['u']=[u,u,a1,a1,a1,a1,a4];f['v']=[u,u,a1,a1,a1,b0,a7];f['w']=[u,u,a9,a9,a9,a9,b0];f['x']=[u,u,a1,b0,a7,b0,a1];f['y']=[u,u,a1,a1,a5,a8,a4];f['z']=[u,u,a3,b5,a7,b2,a3];f['1']=[b4,a7,a7,a7,a7,a7,a3];f['2']=[a2,a8,a8,a4,a6,a6,a3];f['3']=[a2,a8,a8,a4,a8,a8,a2];f['4']=[b6,b0,b3,b3,a3,b5,b5];f['5']=[a3,a6,a6,a2,a8,a8,a2];f['6']=[a5,a6,a6,a2,a1,a1,a4];f['7']=[a3,a8,a8,b5,a7,a7,a7];f['8']=[a4,a1,a1,a4,a1,a1,a4];f['9']=[a4,a1,a1,a5,a8,a8,a2];f['0']=f['O'];f['`']=[a6,b2,a7,u,u,u,u];f['~']=[b7,b3,u,u,u,u,u];f['!']=[a7,a7,a7,a7,a7,u,a7];f['@']=[a2,a8,b7,a9,a9,a9,a4];f['#']=[b0,a3,b0,a3,b0,u,u];f['$']=[a7,a5,a6,a4,a8,a2,a7];f['%']=['25',a9,b0,a7,b0,a9,b3];f['^']=[a7,b0,a1,u,u,u,u];f['&']=[a4,a6,a6,'25',a9,b3,b7];f['*']=[a7,a9,a4,a9,a7,u,u];f['(']=[b6,b2,b2,b2,b2,b2,b6];f[')']=[b6,a8,a8,a8,a8,a8,b6];f[']']=[b1,b5,b5,b5,b5,b5,b1];f['-']=[u,u,u,a3,u,u,u];f['=']=[u,u,a3,u,a3,u,u];f['+']=[u,a7,a7,a3,a7,a7,u];f['[']=[a4,b2,b2,b2,b2,b2,a4];f[']']=[a4,b5,b5,b5,b5,b5,a4];f['{']=[b6,b2,b2,a6,b2,b2,b6];f['}']=[b1,b5,b5,a8,b5,b5,b1];f['|']=[a7,a7,a7,a7,a7,a7,a7];f['\\']=[a6,a6,b2,a7,b5,a8,a8];f['/']=[a8,a8,b5,a7,b2,a6,a6];f['<']=[u,b5,a7,b2,a7,b5,u];f['>']=[u,b2,a7,b5,a7,b2,u];f['?']=[a4,a1,b5,a7,a7,u,a7];f['.']=[u,u,u,u,u,u,a7];f[':']=[u,u,a7,u,u,u,a7];f[';']=[u,u,a7,u,u,a7,b5];f[',']=[u,u,u,u,u,a7,b5];f['\'']=[a7,a7,a7,u,u,u,u];f['"']=[b0,b0,b0,u,u,u,u];f['_']=[u,u,u,u,u,u,a3];f['id']=[u,u,u,u,a6,b0,a7,u];f[' ']=[u,u,u,u,u,u,u];if(n4)window.onResize=rI;function rI(){window.history.go(0);}function w(y,z){y=y.split('');for(i in y)!f[y[i]]?y[i]='id':v;s=u;for(i=0;i<7;i++){for(k in y){for(j=1;j<6;j++){y[k]=='id'?i==2?j==5?s+=sn+"O"+sa:s+=sp:i==3?j==2?s+=sn+"I"+sa:j==4?s+=sn+"E"+sa:s+=sp:i==4?j==3?s+=sn+"D"+sa:s+=sp:s+=sp:f[y[k]][i].indexOf(j)!=-1?s+=z:s+=sp;}s+=sp;}s+=br;}return s;}function e(v){n4?l=d.layers['p']:i4?l=d.all['p']:l=d.getElementById('p');r=v[el][1][vl].split(u);t=d.q1[el][0];z=r[0];y=v[el][0][vl];!n4?i4?l[ih]=br+w(y,z):l[ih]=w(y,z):l.document[wr]('<span style="font-family:Courier;font-size:12px;">'+w(y,z));n4?l.document.close():v;t[vl]=w(y,z);}</SCRIPT>

 

<SCRIPT>di(2,'IDEO ASCII TYPESETTER');di(56,sp);di(2,':)'+br);di(81,'-');</SCRIPT>

 

<FORM name=q><BR><BR>1. 请输入字母:    <INPUT class=g

value=chenxi><BR><BR>2. 请选择一种字符: <INPUT class=g size=5 value=@><BR><BR>3.

Generate ASCII:

  <INPUT class=h onclick=e(d.q) type=button value=Run><BR><BR><BR>

<SCRIPT>di(81,'-');di(2,br+'copy & paste:');di(38,sp);</SCRIPT><BR><BR><BR>

<DIV id=p style="WIDTH: auto; POSITION: absolute; HEIGHT: auto"></DIV>

<SCRIPT>di(11,br);di(81,'-');</SCRIPT>

<BR>copy & paste into html:<BR><BR><BR></FORM>

<FORM name=q1><TEXTAREA rows=3 cols=67></TEXTAREA><BR><BR></FORM>

第二步:把<body>中的内容改为:

<body   onload=e(d.q)>

 

0 Comments

Fri

20

Mar

2009

118、导航条显示完全版

118、导航条显示完全版

脚本说明:

把如下代码加入<body>区域中

<SCRIPT LANGUAGE="JavaScript">

<!-- Begin

function change_colors()

{

text_area.style.scrollbarBaseColor=document.c_form.BaseColor.value

text_area.style.scrollbarArrowColor=document.c_form.ArrowColor.value

text_area.style.scrollbarDarkShadowColor=document.c_form.DarkShadowColor.value

text_area.style.scrollbarFaceColor=document.c_form.FaceColor.value

text_area.style.scrollbarHighlightColor=document.c_form.HighlightColor.value

text_area.style.scrollbarShadowColor=document.c_form.ShadowColor.value

text_area.style.scrollbar3DLightColor=document.c_form.dlightColor.value

if (document.c_form.show_text.value == "Yes")

{

new_window = open("","displayWindow","width=500,height=400,left=10,top=10");

 

// open new document

  new_window.document.open();

// Text of the new document

// Replace your " with ' or \" or your document.write statements will fail

new_window.document.write("<html><title>看导航条设置的源代码</title>");

new_window.document.write("<body bgcolor=\"#FFFFFF\"><center>");

new_window.document.write("<textarea  rows=12 cols=45>");

new_window.document.write("<style type=text/css>body {");

if (c_form.BaseColor.value != "")

{

new_window.document.write("scrollbar-Base-Color:"+document.c_form.BaseColor.value +";");

}

if (c_form.ArrowColor.value != "")

{

new_window.document.write("scrollbar-Arrow-Color="+document.c_form.ArrowColor.value +";");

}

if (c_form.DarkShadowColor.value != "")

{

new_window.document.write("scrollbar-DarkShadow-Color="+document.c_form.DarkShadowColor.value +";");

}

if (c_form.FaceColor.value != "")

{

new_window.document.write("scrollbar-Face-Color="+document.c_form.FaceColor.value +";");

}

if (c_form.HighlightColor.value != "")

{

new_window.document.write("scrollbar-Highlight-Color="+document.c_form.HighlightColor.value +";");

}

if (c_form.ShadowColor.value != "")

{

new_window.document.write("scrollbar-Shadow-Color="+document.c_form.ShadowColor.value +";");

}

if (c_form.dlightColor.value != "")

{

new_window.document.write("scrollbar-3dlight-Color="+document.c_form.dlightColor.value +";");

}

new_window.document.write("}</style></textarea>");

new_window.document.write("</body></html>");

// close the document

  new_window.document.close();

}

}

//  End -->

</script>

 

 

<center>

<textarea name="text_area" cols="45" rows="5">

美国当地时间1127日晚(北京时间28日早)消息,美国防部长拉姆斯菲尔德表示,美军于美国时间27(北京时间28日凌晨)对坎大哈东南的一座设施进行了轰炸,该设施是“基地”恐怖组织头目和塔利班领导人经常出入的地方,很可能是塔利班领导人奥马尔的藏身之地。

 

</textarea>

</center>

 

<div align="center">

<center>

<table width="450">

<tr><td align="center" valign="top" width="112" nowrap>

<form name="c_form">

<div align="center">Base<br>

<select name="BaseColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td><td align="center" valign="top" width="112" nowrap>

Arrow

<br>

<select name="ArrowColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td><td align="center" valign="top" width="112" nowrap>

Dark Shadow

<br>

<select name="DarkShadowColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td>

<td align="center" valign="top" width="112" nowrap>

Face

<br>

<select name="FaceColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td></tr>

<tr><td align="center" valign="top" width="112" nowrap>

Highlight

<br>

<select name="HighlightColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td><td align="center" valign="top" width="112" nowrap>

Shadow

<br>

<select name="ShadowColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td><td align="center" valign="top" width="112" nowrap>

3dlight

<br>

<select name="dlightColor">

<option value="">None</option>

<option value="#000000">Black</option>

<option value="#FFFFFF">White</option>

<option value="#008000">Green</option>

<option value="#800000">Maroon</option>

<option value="#808000">Olive</option>

<option value="#000080">Navy</option>

<option value="#800080">Purple</option>

<option value="#808080">Grey</option>

<option value="#FFFF00">Yellow</option>

<option value="#00FF00">Lime</option>

<option value="#00FFFF">Aqua</option>

<option value="#FF00FF">Fushia</option>

<option value="#C0C0C0">Silver</option>

<option value="#FF0000">Red</option>

<option value="#0000FF">Blue</option>

<option value="#008080">Teal</option>

</select>

 

</td><td align="center" valign="top" width="112" nowrap>

看源代码<br>

<select name="show_text">

<option value="No">No</option>

<option value="Yes">Yes</option>

</select>

</td></tr>

<tr>

<td align="center" valign="top" colspan="4" width="442">

<input type="button" value="显示效果/看源代码" onClick="JavaScript:change_colors()">

</div>

</form>

</td></tr>

</table>

0 Comments

Fri

20

Mar

2009

117、编码互换

117、编码互换

脚本说明:

第一步:把如下代码加入<body>区域中

<script language=JavaScript>

<!--

var i=0;

var ie=(document.all)?1:0;

var ns=(document.layers)?1:0;

 

function initStyleElements() /* Styles for Buttons Init */

{

var c = document.pad;

if (ie)

{

//c.text.style.backgroundColor="#DDDDDD";

c.compileIt.style.backgroundColor="#C0C0A8";

c.compileIt.style.cursor="hand";

c.select.style.backgroundColor="#C0C0A8";

c.select.style.cursor="hand";

c.view.style.backgroundColor="#C0C0A8";

c.view.style.cursor="hand";

c.retur.style.backgroundColor="#C0C0A8";

c.retur.style.cursor="hand";

c.clear.style.backgroundColor="#C0C0A8";

c.clear.style.cursor="hand";

}

else return;

}

 

/* Buttons Enlightment of "Compilation" panel */

function LightOn(what)

{

if (ie) what.style.backgroundColor = '#E0E0D0';

else return;

}

function FocusOn(what)

{

if (ie) what.style.backgroundColor = '#EBEBEB';

else return;

}

function LightOut(what)

{

if (ie) what.style.backgroundColor = '#C0C0A8';

else return;

}

function FocusOff(what)

{

if (ie) what.style.backgroundColor = '#DDDDDD';

else return;

}

/* Buttons Enlightment of "Compilation" panel */

 

function generate() /* Generation of "Compilation" */

{

code = document.pad.text.value;

if (code)

{

document.pad.text.value='正在转换...请稍等!';

setTimeout("compile()",1000);

}

else alert('请先输入一些字符')

}

function compile() /* The "Compilation" */

{

document.pad.text.value='';

compilation=escape(code);

document.pad.text.value="<script>\n<!--\ndocument.write(unescape(\""+compilation+"\"));\n//-->\n<\/script>";

i++;

if (i=1) alert("转换完成!");

else alert("Page compiled "+i+" times!");

}

function selectCode() /* Selecting "Compilation" for Copying */

{

if(document.pad.text.value.length>0)

{

document.pad.text.focus();

document.pad.text.select();

}

else alert('什么也没输入!')

}

function preview() /* Preview for the "Compilation" */

{

if(document.pad.text.value.length>0)

{

pr=window.open("","Preview","scrollbars=1,menubar=1,status=1,width=700,height=320,left=50,top=110");

pr.document.write(document.pad.text.value);

}

else alert('什么也没输入!')

}

function uncompile() /* Decompiling a "Compilation" */

{

if (document.pad.text.value.length>0)

{

source=unescape(document.pad.text.value);

document.pad.text.value=""+source+"";

}

else alert('请先输入一些字符!')

}

// -->

</script>

<form method=post name=pad align=center>

<textarea rows=11 name=text cols=58 style="background-color:#EBEBEB;width:95%"></textarea><br>

<input type=button value=转换 name=compileIt onClick=generate() onMouseOver=LightOn(this) onMouseOut=LightOut(this)>

<input type=button value=选择 name=select onClick=selectCode() onMouseOver=LightOn(this) onMouseOut=LightOut(this)>

<input type=button value=显示 name=view onClick=preview() onMouseOver=LightOn(this) onMouseOut=LightOut(this)>

<input type=button value=来源 name=retur onClick=uncompile() onMouseOver=LightOn(this) onMouseOut=LightOut(this)>

<input type=reset value=清除 name=clear onMouseOver=LightOn(this) onMouseOut=LightOut(this)>

</form>

 

 

第二步:把<body>中的内容改为:

<body onload=initStyleElements()>

 

0 Comments

Fri

20

Mar

2009

116、彩色导航条

116、彩色导航条

脚本说明:

把如下代码加入<head>区域中

<style>

<!--

BODY { scrollbar-face-color:ffffff; scrollbar-shadow-color:ccccff; scrollbar-highlight-color:ccccff; scrollbar-3dlight-color:ccccff; scrollbar-darkshadow-color:006699; scrollbar-track-color:cad5ff; scrollbar-arrow-color:006699; }

-->

</style>

 

0 Comments

Fri

20

Mar

2009

115、打开窗口的移动

115、打开窗口的移动

脚本说明:

把如下代码加入<body>区域中

 <SCRIPT>

       function openWin(url){

        exampleWin = window.open(url, "exampleWin",

           "toolbar=no,directories=no,status=no,location=no,resizable=no,scrollbars=yes,menubar=no,width=700,height=500");

         exampleWin.focus();

         exampleWin.moveTo(300,150);

       }

  </SCRIPT>

<A href="javascript:openWin('http://www.7stk.com')">打开窗口移动到指定位置</A>

 

0 Comments

Fri

20

Mar

2009

114、弹出窗口始终一个

114、弹出窗口始终一个

脚本说明:

<script language="JavaScript">

<!--

function Demo(Page,scrl){

if (false)window.close();

 if  (!window.win || win.closed)  win=open(Page,"","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,top=2,width=300,height=100,scrollbars="+scrl+",resizable=1");

 else{

  win.close();   win=open(Page,"","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,top=2,width=300,height=100,scrollbars="+scrl+",resizable=1");

  }

}

//-->

</script>

<a href="javascript:Demo('http://huicui.jimdo.com/')">链接一</a>

<a href="javascript:Demo('http://huicui.jimdo.com/')">链接二</a>

 

0 Comments

Fri

20

Mar

2009

113、用上下左右键移动页面

113、用上下左右键移动页面

脚本说明:

第一步:把如下代码加入<body>区域中

<script language="JavaScript">

function movepage()

{

var direction =event.keyCode

switch(direction){

case 39:

window.moveBy(15, 0);

window.moveBy(0, 0);

break

case 37:

window.moveBy(-15, 0);

window.moveBy(0, 0);

break

case 38:

window.moveBy(0, 0);

window.moveBy(0, -15);

break

case 40:

window.moveBy(0, 0);

window.moveBy(0, 15);

break

default:

break

}

}

//  End -->

</script>

 

第二步:请把<body>中的内容改为:

<body bgcolor="#fef4d9" onLoad="top.window.focus()" onkeydown="movepage()">

 

0 Comments

Fri

20

Mar

2009

112、title显示关闭时间

112title显示关闭时间

脚本说明:

把如下代码加入<body>区域中

<script language="JavaScript">

<!--

function clock(){

i=i-1

document.title="本窗口将在"+i+"秒后自动关闭";

if(i>0)setTimeout("clock();",1000);

else self.close();

}

var i=10

clock();

//-->

</script>

 

0 Comments

Fri

20

Mar

2009

111、Html与Asp互转工具

111HtmlAsp互转工具

脚本说明:

把如下代码加入<body>区域中:

<SCRIPT language=vbscript>

<!--

function autocr()

if checkbox.checked then

       html.wrap="soft"

       asp.wrap="soft"

       else

       html.wrap="off"

       asp.wrap ="off"

       end if

end function

 

function HtmlToAsp(str)

dim i,AspStr,tmp,st

AspStr=""

for i=1 to Len (str)

       tmp=Mid(str,i,1)

       select case tmp

              case """"

                     if not st then   tmp=""""""

              case "<"

                     if Mid(str,i+1,1)="%" then

                            tmp="""&"

                            if mid(str,i+2,1)="=" then i=i+2 else i=i+1

                            st=true

                            end if

              case "%"

                     if Mid(str,i+1,1)=">" then

                            tmp="&"""

                            st=false

                            i=i+1

                            end if

              end select

       AspStr=AspStr&tmp

       next

HtmlToAsp="Response.Write """&AspStr&"""&VbCrLf"

end function

 

function AspToHtml(str)

dim i,HtmStr,tmp,itmp,st

str=Trim(str)

HtmStr=""

st=3

if strcomp(mid(str,1,14),"Response.Write",1)=0 then str=LTrim(mid(str,15))

for i=1 to Len(str)

       tmp=Mid (str,i,1)

       if tmp="""" then

              if mid(str,i+1,1)="""" and st=1 then

                     tmp=""""

                     i=i+1

              elseif mid(str,i+1,1)="&" and st=1 then

                     st=0

                     if mid(str,i+2,1)="""" then

                            tmp=""

                            st=1

                            i=i+2

                     elseif strcomp(mid(str,i+2,6),"VbCrLf",1)=0 then

                            if i+7=len(str) then tmp="" else tmp=VbCrLf

                            i=i+7

                            else

                            tmp="<%"

                            i=i+1

                            end if

                     elseif st=3 then

                            tmp=""

                            st=1

                     elseif i=len(str) and st=1 then

                            tmp=""

                            st=0

                            end if

              elseif tmp="&" and mid(str,i+1,1)="""" and st=0 then

                            st=1

                            tmp="%>"

                            i=i+1

                            end if

       HtmStr=HtmStr&tmp

       next

AspToHtml=HtmStr

end function

 

 

 

function hta()

dim ahtm,aspstr,inum

if html.value>"" then

       ahtm=Split (html.value ,vbCrLf,-1,0)

       inum=UBound(ahtm)

       for i=0 to inum

              aspstr=aspstr&HtmlToAsp (ahtm(i))

              if i<inum-1 then aspstr=aspstr&vbCrLf

              next

       asp.value =aspstr

       end if

end function

 

function ath()

dim aasp,htmstr,inum

if asp.value>"" then

       aasp=Split (asp.value ,vbCrLf,-1,0)

       inum=UBound (aasp)

       for i=0 to inum

              htmstr=htmstr&AspToHtml (aasp(i))

              if i<inum-1 then htmstr =htmstr &vbCrLf

              next

       html.value =htmstr

       end if

end function

 

function selall(obj)

obj.select

end function

-->

</SCRIPT>

<TABLE id=AutoNumber1 style="BORDER-COLLAPSE: collapse" borderColor=#111111

cellSpacing=0 cellPadding=5 width="100%" border=0>

  <TBODY>

  <TR>

    <TD width="100%" colSpan=3><TEXTAREA class=myinput onfocus=selall(html) name=html rows=10 wrap=off cols=102></TEXTAREA>

    </TD></TR>

  <TR>

    <TD width="40%">

      <P align=right><INPUT class=mybutton style="WIDTH: 150px; HEIGHT: 25px" onclick=hta type=button value=HTMLASP name=toasp>

      </P></TD>

    <TD width="16%">  <INPUT onclick=autocr type=checkbox value=checkbox

      name=checkbox> 自动换行</TD>

    <TD width="44%"><INPUT class=mybutton style="WIDTH: 150px; HEIGHT: 25px" onclick=ath type=button value=ASPHTML name=tohtml>

    </TD></TR>

  <TR>

    <TD width="100%" colSpan=3><TEXTAREA class=myinput onfocus=selall(asp) name=asp rows=10 wrap=off cols=102></TEXTAREA>

    </TD></TR>

  <TR align=middle>

    <TD width="100%" colSpan=3>  </TD></TR></TBODY></TABLE>

 

 

0 Comments

Fri

20

Mar

2009

110、退出时弹出窗口

110、退出时弹出窗口

脚本说明:

把如下代码加入<body>区域中

<body onunload="open('about:<b>这是关闭前面一个窗口时出现的弹出窗口:<p><A href=http://www.7stk.com>去这里看看吧</a><p>这些内容都是用HTML代码写的,好好看看吧','','')">

 

0 Comments

Fri

20

Mar

2009

109、子父窗口的刷新

109、子父窗口的刷新

脚本说明:

在弹出窗口中加入如下代码:

<BODY onunload="window.opener.location.reload();" >

 

0 Comments

Fri

20

Mar

2009

108、select自动回答问题

108select自动回答问题

脚本说明:

把如下代码加入<body>区域中

<form name="form1">

<table border="0">

<tr>

<td>

<SCRIPT LANGUAGE="JavaScript">

<!--

function showAnswer(whatForm){

if(document.forms[whatForm].question.value=="none"){

document.forms[whatForm].answer.value="^请选择一个问题:^"

}else{

document.forms[whatForm].answer.value=document.forms[whatForm].question.value

}}

// -->

</script>

<b>问题:</b>

</td>

 

<td valign="top"><select name="question" size="1" onchange="showAnswer('form1')">

<option value="">请选择一个问题 </option>

<option value="当然是'网络时空'-www.k688.com,呵呵...">你最喜欢的站点是什么站点?</option>

<option value="200110月,中央电视台“焦点访谈”报道了“学生停课捡棉花”的问题,在敦煌市上下引起了强烈的反响,也极大地震动了该市的各级领导。不料,在此之后记者去敦煌市采访,所到之处均遭到被采访单位的拒绝。一个开放的旅游城市,为何会出现这种情况?记者感到十分纳闷。经多方了解后得知,原来敦煌市于不久前出台了《关于加强驻敦记者站和来敦记者新闻采访活动管理的意见》,导致全市有关部门和各单位对新闻采访噤若寒蝉。">今天的特大新闻是什么?</option>

<option value="不小了,但是就不告诉你">你多大了?</option>

</select>

</td>

</tr>

<tr>

<td align="right" valign=top><b>回答:</b> </td>

<td><textarea name="answer" rows="8" cols="40" readonly>

 

0 Comments

Fri

20

Mar

2009

107、广告的定时显示隐藏

107、广告的定时显示隐藏

脚本说明:

把如下代码加入<body>区域中:

<SCRIPT language=JavaScript>

<!--

SYfullscreen=true

var adInterPath="test0123.htm"

if (document.all) {

// this is a 4.x browser, no?

document.write('<SCRI' + 'PT LANGUAGE="javascript1.2"');

document.writeln(' SRC="interstitial.js"></SCR' + 'IPT>');

}

// -->

</SCRIPT>

<DIV id=hiddenLayer style="DISPLAY: none">

      <SCRIPT language=Javascript>

<!--

       if (getsGlu) {

              expandableIframe = '<IFRAME id="interstitialframe" width=468 HEIGHT=60 NORESIZE SCROLLING=No FRAMEBORDER=0 MARGINHEIGHT=0 MARGINWIDTH=0></IFRAME>';

              document.write(expandableIframe);

       }

// -->

</SCRIPT></DIV>

 

0 Comments

Fri

20

Mar

2009

106、重要信息说明脚本

106、重要信息说明脚本

脚本说明:

第一步:把如下代码加入<body>区域中

<script language="javascript">

//显示的信息,可以使用HTML语法,注意引号用法,单套双。

var message='<b><font size=5 face=arial color=red><a href="http://www.7stk.com/bbs" target="_blank">请点击进入本站BBS</a></font></b>'

 

//背景色

var backgroundcolor="#eeffee"

 

//0 代表信息永远显示,1 代表信息只显示一段时间,2为随机显示模式;

var displaymode=1

 

//如果显示模式为在指定时间内显示,输入时间段(10001)

var displayduration=30000

 

//1代表闪烁,0代表不闪烁;

var flashmode=1

//如果设置了闪烁,输入闪烁的颜色;

var flashtocolor="lightgreen"

 

////下面不必修改///

 

 

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>

 

0 Comments

Fri

20

Mar

2009

105、倒计时载入页面

105、倒计时载入页面

脚本说明:

第一步:把如下代码加入<head>区域中:

 <META HTTP-EQUIV="REFRESH" CONTENT="11; URL=http://www.7stk.com">

 

 

第二步:<body>中加入如下代码:

 <META HTTP-EQUIV="REFRESH" CONTENT="11; URL=http://www.7stk.com">

 

 <script language="JavaScript">

 

 startday = new Date();

 clockStart = startday.getTime();

 

 function initStopwatch()

 {

  var myTime = new Date();

         var timeNow = myTime.getTime(); 

         var timeDiff = timeNow - clockStart;

         this.diffSecs = timeDiff/1000;

         return(this.diffSecs);

 }

 

 function getSecs()

 {

         var mySecs = initStopwatch();

         var mySecs1 = ""+mySecs;

         mySecs1= mySecs1.substring(0,mySecs1.indexOf(".")) + " secs.";

         document.form1.timespent.value = mySecs1

         window.setTimeout('getSecs()',1000);

 }

 

 

 </script>

 

 

  <center>

 This page will change in 10 seconds:

 <form name=form1><input size=9 name=timespent></form>

 </center>

 

第三步:把<body>中内容改为:

<body bgcolor="#fef4d9" onLoad="window.setTimeout('getSecs()',1)">

      

 

0 Comments

Fri

20

Mar

2009

104、关闭窗口的提示

104、关闭窗口的提示

脚本说明:

把如下代码加入<body>区域中

<body onbeforeunload="return '可不要随便关闭这个窗口哟'">

 

0 Comments

Fri

20

Mar

2009

103、极酷的Word网页编辑器

103、极酷的Word网页编辑器

0 Comments

Fri

20

Mar

2009

102、检查窗口的关闭打开

102、检查窗口的关闭打开

脚本说明:

把如下代码加入<body>区域中

<script>

var newwin

function makenewwin() {

newwin=window.open("","vv","height=300,width=200")

newwin.document.writeln("ok")

newwin.document.close()

}

function check() {

if (newwin&&newwin.open&&!newwin.closed){

alert("开的")

}

else{

alert("关的")

}

}

</script>

<input type="button" value="open" onclick="makenewwin()">

<input type="button" value="检查" onclick="check()">

 

0 Comments

Fri

20

Mar

2009

101、打开无边窗口

101、打开无边窗口

脚本说明:

把如下代码加入<body>区域中

<script language=javascript>

 

minimizebar="minimize0604.gif"; //nbw窗口右上角最小化“按钮”的图片

closebar="close0604.gif";       //nbw窗口右上角关闭“按钮”的图片

icon="icon0604.gif";            //nbw窗口左上角的小图标

 

function noBorderWin(fileName,w,h,titleBg,titleColor,titleWord,borderColor,scr)

/*

------------------参数说明-------------------

fileName   :无边窗口中显示的文件。

w       :窗口的宽度。

h       :窗口的高度。

titleBg    :窗口“标题栏”的背景色。

titleColor :窗口“标题栏”文字的颜色。

titleWord  :窗口“标题栏”的文字。

borderColor:窗口“边框”的颜色。

scr        :是否出现滚动条。取值yes/no或者1/0

--------------------------------------------

*/

{

  nbw=window.open('','','fullscreen=yes');

  nbw.resizeTo(w,h);

  nbw.moveTo((screen.width-w)/2,(screen.height-h)/2);

  nbw.document.writeln("<title>"+titleWord+"</title>");

  nbw.document.writeln("<"+"script language=javascript"+">"+"cv=0"+"<"+"/script"+">");

  nbw.document.writeln("<body topmargin=0 leftmargin=0 scroll=no>");

  nbw.document.writeln("<table cellpadding=0 cellspacing=0 width=300 height=100% style=\"border: 1px solid "+borderColor+"\">");

  nbw.document.writeln("  <tr bgcolor="+titleBg+" height=20 onselectstart='return false' onmousedown='cv=1;x=event.x;y=event.y;setCapture();' onmouseup='cv=0;releaseCapture();' onmousemove='if(cv)window.moveTo(screenLeft+event.x-x,screenTop+event.y-y);'>");

  nbw.document.writeln("    <td width=21 align=left><img width=12 width=12 src="+icon+"></td>");

  nbw.document.writeln("    <td style=\"font-family:宋体; font-size:12px; color:"+titleColor+";\"><span style='top:1;position:relative;cursor:default;'>"+titleWord+"</span></td>");

  nbw.document.writeln("    <td align=right width=30 style=font-size:16px>");

  nbw.document.writeln("      <img border=0 width=12 height=12 alt=最小化 src="+minimizebar+" onclick=window.blur();>");

  nbw.document.writeln("      <img border=0 width=12 height=12 alt=关闭 src="+closebar+" onclick=window.close();>");

  nbw.document.writeln("    </td>");

  nbw.document.writeln("  </tr>");

  nbw.document.writeln("  <tr>");

  nbw.document.writeln("    <td colspan=3><iframe frameborder=0 width=100% height=100% scrolling="+scr+" src="+fileName+"></iframe></td>");

  nbw.document.writeln("  </tr>");

  nbw.document.writeln("</table>");

}

</script>

<!----------------- 一个应用的例子 ----------------->

<button onclick=noBorderWin('http://www.7stk.com','300','240','#000000','#CCCCCC','一个无边窗口的测试例子','#000000','no');>打开无边窗口</button>

 

0 Comments

Fri

20

Mar

2009

100、打开特殊的窗口

100、打开特殊的窗口

脚本说明:

把如下代码加入<body>区域中

<A HREF="javascript:openIT('http://www.7stk.com')">请按此打开窗口,要打开的网址也写在这个链接里</A>

<SCRIPT LANGUAGE="JavaScript">function openIT(theURL){

//主要改这里的内容

W=300;

H=408;

windowCERRARa="1003.gif"

windowCERRARd="1004.gif"

windowCERRARo="1005.gif"

windowNONEgrf="2309.gif"

windowCLOCK="1002.gif"

windowREALtit="建站资源"

windowTIT="<font face=verdana size=2>.::网络时空::.</font>"

windowBORDERCOLOR="#f1950a"

windowBORDERCOLORsel="#f1950a"

windowTITBGCOLOR="#f1950a"

windowTITBGCOLORsel="#66614a"

 

//以下内容不用改

 

wname=Math.floor(Math.random()*10000);

openchromeless(theURL, wname, W, H, windowCERRARa, windowCERRARd, windowCERRARo, windowNONEgrf, windowCLOCK, windowTIT, windowREALtit , windowBORDERCOLOR, windowBORDERCOLORsel, windowTITBGCOLOR, windowTITBGCOLORsel)}

function openchromeless(theURL, wname, W, H, windowCERRARa, windowCERRARd, windowCERRARo, windowNONEgrf,windowCLOCK, windowTIT, windowREALtit , windowBORDERCOLOR, windowBORDERCOLORsel, windowTITBGCOLOR, windowTITBGCOLORsel) {

var windowW=W;

var windowH=H;

var windowX=Math.ceil( (window.screen.width  - windowW) / 2 );

var windowY=Math.ceil( (window.screen.height - windowH) / 2 );

if (navigator.appName=="Microsoft Internet Explorer" && parseInt(navigator.appVersion)>=4) isie=true

else isie=false

if (isie) { H=H+20+2;W=W+2;}

s=",width="+W+",height="+H;

 

if (isie && (navigator.userAgent.toLowerCase().indexOf("win")!=-1) ) {

var dowin=theURL !="" ? true : false;

var chromeTIThtml='\n'+

'<html>'+'\n'+

'<head> '+'\n'+

'<title> CHROMELESS WINDOWS / TITLEBAR</title>  '+'\n'+

'<style type="text/css">  '+'\n'+

'#mywindowTITLE { position: absolute;left: 0px;top: 0px;width: 100%;height: 22px;z-index: 1;background-color: '+windowTITBGCOLOR+';clip:rect(0,100%,22,0);} '+'\n'+

'#mywindow { position: absolute;left: 0px;top: 0px;width: 100%;height: 22px;z-index: 2;clip:rect(0,100%;22,0);} '+'\n'+

'#mywindowCLOSE { position: absolute;left: -22px;top: -22px;width: 11px;height: 11px;z-index: 3;clip:rect(0,11,11,0);} '+'\n'+

'#mywindowCLOCK { position: absolute;left: -22px;top: -22px;width: 11px;height: 11px;z-index: 3;clip:rect(0,11,11,0);} '+'\n'+

'</style> '+'\n'+

'<scr'+'ipt language="javascript">'+'\n'

chromeTIThtml=chromeTIThtml+

'theURL="'+theURL+'" '+'\n'+

'windowCERRARa="'+windowCERRARa+'" '+'\n'+

'windowCERRARd="'+windowCERRARd+'" '+'\n'+

'windowCERRARo="'+windowCERRARo+'" '+'\n'+

'windowCLOCK="'+windowCLOCK+'"'+'\n'+

'windowBORDERCOLOR="'+windowBORDERCOLOR+'" '+'\n'+

'windowBORDERCOLORsel="'+windowBORDERCOLORsel+'" '+'\n'+

'windowTITBGCOLOR="'+windowTITBGCOLOR+'" '+'\n'+

'windowTITBGCOLORsel="'+windowTITBGCOLORsel+'" '+'\n'

chromeTIThtml=chromeTIThtml+

'var windowCERRARImg_a=new Image();windowCERRARImg_a.src=windowCERRARa;'+'\n'+

'var windowCERRARImg_d=new Image();windowCERRARImg_d.src=windowCERRARd;'+'\n'+

'var windowCERRARImg_o=new Image();windowCERRARImg_o.src=windowCERRARo;'+'\n'+

'var windowCLOCKImg=new Image();windowCLOCKImg.src=windowCLOCK;'+'\n'+'\n'+

'function mouseSTATUS(){'+

'this.x=null;'+'\n'+

'this.y=null;'+'\n'+

'this.bt="up";'+'\n'+

'this.oldx=null;'+'\n'+

'this.oldy=null;'+'\n'+

'this.dx=null;'+'\n'+

'this.dy=null;'+'\n'+

'this.screeny=null;'+'\n'+

'this.screenx=null;'+'\n'+

'this.element=null;'+'\n'+

'this.event=null;'+'\n}'+

 

'var mouse=new mouseSTATUS();'+'\n'+

'function actualizateMouseSTATUS(e) { '+'\n'+

'if (!e) var e=event '+'\n'+

'if ( (e.type=="mousedown" || e.type=="mouseup") && e.button!=1) return true '+'\n'+

'var x=e.x+document.body.scrollLeft  '+'\n'+

'var y=e.y+document.body.scrollTop '+'\n'+

'mouse.x=x;'+'\n'+

'mouse.y=y;'+'\n'+

' if ( e.type=="mousedown" ) mouse.bt="down";'+'\n'+

'else if ( e.type=="mouseup" ) mouse.bt="up";'+'\n'+

'if (window.event) { '+'\n'+

'mouse.screenx=window.event.screenX;'+'\n'+

'mouse.screeny=window.event.screenY;'+'\n'+

'} else {  '+'\n'+

'mouse.screenx=-1;'+'\n'+

'mouse.screeny=-1;'+'\n}'+

'}'+

'function initMouseEvents() { '+'\n'+

'document.onmousedown=actualizateMouseSTATUS '+'\n'+

'document.onmousemove=actualizateMouseSTATUS '+'\n'+

'document.onmouseup=actualizateMouseSTATUS '+'\n'+

'document.onselectstart=selectstart  '+'\n'+

'document.ondragstart=new Function("actualizateMouseSTATUS(event);return false;") '+'\n'+

'}  '+'\n'+

 

'function selectstart(){  '+'\n'+

'if ( event.srcElement.tagName !="INPUT" && event.srcElement.tagName !="TEXTAREA") { return false;} '+'\n'+

'else { mouse.bt="up";return true;}  '+'\n'+

'}  '+'\n'+

 

'initMouseEvents()  '+'\n'+

 

'var mywindowbt="up";'+'\n'+

'var wincloseSTATUS="up";'+'\n'+

 

'var ofx=0;'+'\n'+

'var ofy=0;'+'\n'+

'var opx=0;'+'\n'+

'var opy=0;'+'\n'+

'var px=0;'+'\n'+

'var py=0;'+'\n'+

 

'var wcpx1=-1, wcpy1=-1;'+'\n'+

'var wcpx2=-1, wcpy2=-1;'+'\n'+

 

'var wclosechanged=false;'+'\n'+

 

'function initToMoveWin() { '+'\n'+

'if (wincloseSTATUS=="up" && ( mywindowbt=="up" || mywindowbt=="over") ) { '+'\n'+

 

'document.all["mywindowCLOCK"].style.pixelLeft=document.body.clientWidth-36 '+'\n'+

'document.all["mywindowCLOCK"].style.pixelTop=4 '+'\n'+

 

'wcpx1=document.all["mywindowCLOSE"].style.pixelLeft=document.body.clientWidth-18  '+'\n'+

'wcpy1=document.all["mywindowCLOSE"].style.pixelTop=4 '+'\n'+

'wcpx2=wcpx1+11 - 1  '+'\n'+

'wcpy2=wcpy1+11 - 1  '+'\n'+

'if ( mouse.x >=wcpx1 && mouse.x <=wcpx2 && mouse.y >=wcpy1 && mouse.y <=wcpy2) {  '+'\n'+

'if (wclosechanged==false) { '+'\n'+

'document.all["mywindowCLOSE"].document.images["closewin"].src=windowCERRARImg_o.src '+'\n'+

'wclosechanged=true  '+'\n'+

'}'+

 

'} else if (wclosechanged==true) { '+'\n'+

'document.all["mywindowCLOSE"].document.images["closewin"].src=windowCERRARImg_d.src '+'\n'+

'wclosechanged=false '+'\n'+

'}'+

'}'+

 

' if ( mouse.y <=22 && mouse.y >=1 && mywindowbt=="up" && mouse.bt=="up"  ) { mywindowbt="over" } '+'\n'+

'else if ( ( mouse.y  > 22 || mouse.y <  1 ) && mywindowbt=="over" && mouse.bt=="up"  ) { mywindowbt="up" } '+'\n'+

'else if ( mouse.y <=22 && mouse.y >=1 && mywindowbt=="over" && mouse.bt=="down" ) { '+'\n'+

'self.window.focus();'+'\n'+

 

'if ( mouse.x >=wcpx1 && mouse.x <=wcpx2 && mouse.y >=wcpy1 && mouse.y <=wcpy2 ) { '+'\n'+

'wincloseSTATUS="down" '+'\n'+

'document.all["mywindowCLOSE"].document.images["closewin"].src=windowCERRARImg_a.src'+'\n'+

'} else {  '+'\n'+

'document.all["mywindowTITLE"].style.backgroundColor=windowTITBGCOLORsel '+'\n'+

'document.body.style.borderColor=windowBORDERCOLORsel '+'\n'+

'parent.chromewinb.document.bgColor=windowBORDERCOLORsel '+'\n'+

'parent.chromewinl.document.bgColor=windowBORDERCOLORsel '+'\n'+

'parent.chromewinr.document.bgColor=windowBORDERCOLORsel '+'\n'+

'ofx=mouse.x;'+'\n'+

'ofy=mouse.y;'+'\n'+

'opx=mouse.x;'+'\n'+

'opy=mouse.y;'+'\n'+

'}  '+'\n'+

'mywindowbt="down";'+'\n'+

'}'+

'else if ( mouse.bt=="up" && mywindowbt=="down" ) { '+'\n'+

'mywindowbt="up";'+'\n'+

'ofx=0;'+'\n'+

'ofy=0;'+'\n'+

'opx=0;'+'\n'+

'opy=0;'+'\n'+

 

'if ( mouse.x >=wcpx1 && mouse.x <=wcpx2 && mouse.y >=wcpy1 && mouse.y <=wcpy2 && wincloseSTATUS=="down" ) { top.window.close() }  '+'\n'+

 

'wincloseSTATUS="up" '+'\n'+

 

'if ( document.all["mywindowTITLE"] ) {  '+'\n'+

'document.all["mywindowTITLE"].style.backgroundColor=windowTITBGCOLOR  '+'\n'+

'document.body.style.borderColor=windowBORDERCOLOR '+'\n'+

'parent.chromewinb.document.bgColor=windowBORDERCOLOR '+'\n'+

'parent.chromewinl.document.bgColor=windowBORDERCOLOR '+'\n'+

'parent.chromewinr.document.bgColor=windowBORDERCOLOR '+'\n'+

'}}'+

'else if ( mywindowbt=="down" && wincloseSTATUS=="up") { '+'\n'+

'var m_scrx=mouse.screenx;'+'\n'+

'var m_scry=mouse.screeny;'+'\n'+

'opx=px+ofx - m_scrx;'+'\n'+

'opy=py+ofy - m_scry;'+'\n'+

'px=m_scrx - ofx;'+'\n'+

'py=m_scry - ofy;'+'\n'+

'top.window.moveTo(px , py);'+'\n}'+

'setTimeout("initToMoveWin()",50);}'+

'</scr'+'ipt>'+

'</head>  '+'\n'+

'<body TOPMARGIN=0 LEFTMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0 scroll=no style="border: 1px solid '+windowBORDERCOLOR+';overflow: hidden;margin: 0pt;" bgcolor='+windowTITBGCOLOR+'>  '+'\n'+

'<div id=mywindow><img src="'+windowNONEgrf+'" width=100% height=20></div> '+'\n'+

'<div id=mywindowTITLE>'+'<table width=100% height=20 border=0 cellpadding=0 cellspacing=0><tr><td valign=middle align=left>'+windowTIT+'</td></tr></table>'+'</div>  '+'\n'+

'<div id=mywindowCLOSE><img name=closewin src="'+windowCERRARd+'" border=0 width=11 height=11></div>  '+'\n'+

'<div id=mywindowCLOCK><img name=clockwin src="'+windowCLOCK+'" border=0 width=11 height=11></div>  '+'\n'+

'</body>  '+'\n'+

'<scr'+'ipt>initToMoveWin();</scr'+'ipt>'+'\n'+

'</html>  '+'\n'

 

var chromeFRMhtml=''+

'<HTML>'+'\n'+

'<HEAD> '+'\n'+

'<TITLE>'+windowREALtit+'</TITLE>  '+'\n'+

'</HEAD>  '+'\n'+

'<scr'+'ipt> '+'\n'+

'mainloaded=false'+'\n'+

'function generatetitle() { '+'\n'+

'if( window.frames["chromewint"] && window.frames["chromewinl"] && window.frames["chromewinb"] && window.frames["chromewinr"] ) {'+'\n'+

'chromewint.document.open();'+'\n'+

'chromewint.document.write( "'+quitasaltolinea(chromeTIThtml)+'" );'+'\n'+

'chromewint.document.close();'+'\n'+

'chromewinl.document.bgColor="'+windowBORDERCOLOR+'"'+'\n'+

'chromewinb.document.bgColor="'+windowBORDERCOLOR+'"'+'\n'+

'chromewinr.document.bgColor="'+windowBORDERCOLOR+'"'+'\n'+

'}else{'+

'setTimeout("generatetitle()",200)'+'\n'+

'}'+'\n'+

'}'+'\n'+

'generatetitle()'+'\n'+

'</scr'+'ipt>'+'\n'+

'<frameset border=0 framespacing=0 frameborder=0 rows="22,100%,1" onload="mainloaded=true" onreadystatechange="generatetitle()">'+'\n'+

'<frame name=chromewint src="about:blank" scrolling=no noresize>  '+'\n'+

'<frameset border=0 framespacing=0 frameborder=0 cols="1,100%,1">  '+'\n'+

'<frame name=chromewinl src="about:blank" scrolling=no noresize> '+'\n'+

'<frame name=main src="'+theURL+'"> '+'\n'+

'<frame name=chromewinr src="about:blank" scrolling=no noresize> '+'\n'+

'</frameset> '+'\n'+

'<frame name=chromewinb src="about:blank" scrolling=no noresize> '+'\n'+

'</frameset>  '+'\n'+

'</HTML>'

 

splashWin=window.open("", wname, "fullscreen=1,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0"+s);

splashWin.resizeTo(Math.ceil(W) , Math.ceil(H));

splashWin.moveTo(Math.ceil(windowX) , Math.ceil(windowY));

splashWin.document.open();splashWin.document.write(chromeFRMhtml);splashWin.document.close();}

else{var splashWin=window.open(theURL, wname, "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1"+s, true);}

splashWin.focus();}

function quitasaltolinea(txt) {

var salida=txt.toString()

var re=/\\/g;var salida=salida.replace(re, "\\\\");

var re=/\//g;var salida=salida.replace(re, "\\\/");

var re=/\"/g;var salida=salida.replace(re, "\\\"");

var re=/\'/g;var salida=salida.replace(re, "\\\'");

var re=/\n/g;var salida=salida.replace(re, "\\n");

var re=/  /g;var salida=salida.replace(re, "");

var re=/\t/g;var salida=salida.replace(re, "");

var re=/\r/g;var salida=salida.replace(re, "");

return salida}

</SCRIPT>

 

 

0 Comments

Fri

20

Mar

2009

99、对数运算

99、对数运算

脚本说明:

把如下代码加入<body>区域中

<script language="JavaScript">

 

function anylog(form)

{

var a = eval(form.a.value);

var b = eval(form.b.value);

var c = (Math.log(b))/(Math.log(a))

var d = Math.round(1000000*c)/1000000

form.z.value = d

}

</script>

<form>

<table border=3 cellspacing=2 cellpadding=5>

<tr>

<td colspan=2 align=center>log<sub>A</sub>B</td>

</tr>

<tr>

<td align=center><i>A</i></td>

<td align=center><i>B</i></td>

</tr>

<tr>

<td align=center><input type=text name=a size=20></td>

<td align=center><input type=text name=b size=20></td>

</tr>

<tr>

<td align=center><input type=button value="请看答案" onclick="anylog(this.form)"></td>

<td align=center><input type=text name=z size=20></td>

</tr>

</table>

</form>

 

0 Comments

Fri

20

Mar

2009

98、以e为底的对数

98、以e为底的对数

脚本说明:

把如下代码加入<body>区域中

<script language="JavaScript">

 

function ln(form)

{

var a = eval(form.a.value);

var b = Math.log(a)

form.z.value = b

}

</script>

<form>

<table border=3 cellspacing=2 cellpadding=5>

<tr>

<td align=center>A from log<sub><i>e</i></sub>A</td>

<td align=center><i>log<sub><i>e</i></sub>A=</i></td>

</tr>

<tr>

<td align=center><input type=text name=a size=20></td>

<td align=center><input type=text name=z size=20></td>

</tr>

<tr>

<td colspan=2 align=center><input type=button value="请看答案" onclick="ln(this.form)"></td>

</tr>

</table>

</form>

 

0 Comments

Fri

20

Mar

2009

97、VML赏析五

97VML赏析五

0 Comments

Fri

20

Mar

2009

96、VML赏析三

96VML赏析三

0 Comments

Fri

20

Mar

2009

95、VML赏析四

95VML赏析四

0 Comments

Fri

20

Mar

2009

93、 ML赏析一

93 ML赏析一

 

 

0 Comments

Fri

20

Mar

2009

92、 "科学"算命

92 "科学"算命

脚本说明:

把如下代码加入<body>区域中

<SCRIPT LANGUAGE="JavaScript">

function mod(x, x_div){

for (var i=x; i>=x_div; i -= x_div)

return i;

}

function checkNum(str, min, max) {

if (str == "") {

alert("请填写完整");

return false;    }

 

 

 

for (var i = 0; i < str.length; i++) {

 

var ch = str.substring(i, i + 1);

 

if (ch < "0" || ch > "9") {

 

alert("请输入数字!");

 

return false;

 

}}

 

var val = parseInt(str, 10);

 

if ((val < min) || (val > max)) {

 

alert("请输入1 "+max+"之间的数字.");

 

return false;

}

 

 

 

return true;

}

 

function pastlife(form){

var sex;

if ((checkNum(form.day.value,1,31)) && (checkNum(form.month.value,1,12)) &&

(checkNum(form.year.value,0,99)))  {      

 

       var day = parseInt(form.day.value,10);

 

       var cur_month = parseInt(form.month.value,10);

 

       var cur_year = parseInt(form.year.value,10);

 

 

 

       if (cur_month-2*(parseInt(cur_month/2)) == 0){

 

              if (cur_year - 4*(parseInt(cur_year/4)) == 0)

 

                     sex = 1; else sex = 2}

 

             else if (cur_year - 4*(parseInt(cur_year/4)) == 0)

 

                     sex = 0; else sex = 1};

 

       msgWindow=window.open("","有神者说");

 

       msgWindow.document.open();

 

       msgWindow.document.bgColor="black";

 

       msgWindow.document.writeln("<FONT Color=red Face=Arial><B><I>Diagnosis:</I></B></FONT><BR>");   

 

       msgWindow.document.write("<FONT Color=white Face=Arial>");

 

       msgWindow.document.write("我不知道你的感觉如何,但你曾是");

 

 

       var yearString = "ZYXWOTZYQVUTSXWVNZYXPQTZRWVUMYXWOTZYQVUTSXWVNZYXPUTZRWVUMYXWOTZYQVUTSXWVNZYXPUTZRWVUMYXWOTZYQVUTSXWV";

 

 

 

       var ys; ys = yearString.charAt(cur_year);

 

 

 

       var p1; var p2; var place;

 

       if (sex == 1){

 

 

 

              msgWindow.document.write("<FONT color=yellow>男性</FONT>");

 

 

 

 

 

 

 

 

       var indexString = "VTWZXYURPSOMNQYWZVTUXOMPSQRNWUXTYZVMRNQOPSUZVYWXTRPSOMNQTYUXVWZPNQMRSOYWZVTUXNSORPQM";

 

 

 

      

 

 

 

       var profString = "CDBADCABBACD";

 

 

 

             

 

       p1 = profString.charAt(cur_month-1);

 

       for (i=0;i<=6;i++){

 

              if (ys == indexString.charAt((cur_month-1)*7+i)) break}

 

       p2 = i+1;

 

 

       if (p2 == 1){

 

              if (day < 3) place=5;

 

              else if (day < 10) place=46;

 

              else if (day < 17) place=37;

 

              else if (day < 24) place=48;

 

 

 

              else if (day < 31) place=65;

 

 

 

              else place=6};

 

       if (p2 == 2){

 

              if (day < 8) place=28;

 

              else if (day < 15) place=58;

 

              else if (day < 22) place=10;

 

              else if (day < 29) place=38;

 

 

 

              else place=11};

       if (p2 == 3){

              if (day < 4) place=29;

 

 

 

              else if (day < 11) place=53;

 

 

 

              else if (day < 18) place=30;

 

 

 

              else if (day < 25) place=69;

 

 

 

              else place=1};

 

 

       if (p2 == 4){

 

 

 

              if (day < 7) place=74;

 

 

 

              else if (day < 14) place=4;

 

 

 

              else if (day < 21) place=47;

 

 

 

              else if (day < 28) place=20;

 

 

 

              else place=26};

 

 

 

 

 

 

 

       if (p2 == 5){

 

 

 

              if (day < 5) place=23;

 

 

 

              else if (day < 12) place=21;

 

 

 

              else if (day < 19) place=44;

 

 

 

              else if (day < 26) place=16;

 

 

 

              else place=43};

 

 

 

 

 

 

 

       if (p2 == 6){

 

 

 

              if (day < 6) place=34;

 

 

 

              else if (day < 13) place=27;

 

 

 

              else if (day < 20) place=14;

 

 

 

              else if (day < 27) place=41;

 

 

 

              else place=50};

 

 

 

 

 

 

 

       if (p2 == 7){

 

 

 

              if (day < 2) place=73;

 

 

 

              else if (day < 9) place=63;

 

 

 

              else if (day < 16) place=66;

 

 

 

              else if (day < 23) place=54;

 

 

 

              else if (day < 30) place=61;

 

 

 

              else place=72}

 

 

 

}

 

 

 

       else {

 

 

 

       //for females

 

 

 

 

 

 

 

              msgWindow.document.write("<FONT color=yellow>女性</FONT>");

 

 

 

 

 

 

 

       var indexString = "OMPSQRNYWZVTUXSQMPNORUZVYWXTQORNSMPZXTWUVYOMPSQRNXVYUZTWNSORPQMVTWZXYUSQMPNORTYUXVWZ";

 

 

 

      

 

 

 

       var profString = "ACDBCABDDBCA";

 

 

 

             

 

 

 

       p1 = profString.charAt(cur_month-1);

 

 

 

      

 

 

 

       for (i=0;i<=6;i++){

 

 

 

              if (ys == indexString.charAt((cur_month-1)*7+i)) break}

 

 

 

 

 

 

 

       p2 = i+1;

 

 

 

 

 

              //PLACE OF BIRTH Female

 

 

 

 

 

 

 

       if (p2 == 1){

 

 

 

              if (day < 3) place=22;

 

 

 

              else if (day < 10) place=17;

 

 

 

              else if (day < 17) place=36;

 

 

 

              else if (day < 24) place=59;

 

 

 

              else if (day < 31) place=51;

 

 

 

              else place=9};

 

 

 

 

 

 

 

       if (p2 == 2){

 

 

 

              if (day < 8) place=40;

 

 

 

              else if (day < 15) place=2;

 

 

 

              else if (day < 22) place=64;

 

 

 

              else if (day < 29) place=56;

 

 

 

              else place=35};

 

 

 

 

 

 

 

       if (p2 == 3){

 

 

 

              if (day < 4) place=19;

 

 

 

              else if (day < 11) place=67;

 

 

 

              else if (day < 18) place=13;

 

 

 

              else if (day < 25) place=32;

 

 

 

              else place=31};

 

 

 

 

 

 

 

 

       if (p2 == 4){

 

 

 

              if (day < 7) place=15;

 

 

 

              else if (day < 14) place=49;

 

 

 

              else if (day < 21) place=12;

 

 

 

              else if (day < 28) place=39;

 

 

 

              else place=33};

 

 

 

 

 

 

 

       if (p2 == 5){

 

 

 

              if (day < 5) place=42;

 

 

 

              else if (day < 12) place=60;

 

 

 

              else if (day < 19) place=24;

 

 

 

              else if (day < 26) place=3;

 

 

 

              else place=52};

 

 

 

 

 

 

 

       if (p2 == 6){

 

 

 

              if (day < 6) place=18;

 

 

 

              else if (day < 13) place=25;

 

 

 

              else if (day < 20) place=57;

 

 

 

              else if (day < 27) place=45;

 

 

 

              else place=62};

 

 

 

 

 

 

 

       if (p2 == 7){

 

 

 

              if (day < 2) place=8;

 

 

 

              else if (day < 9) place=55;

 

 

 

              else if (day < 16) place=70;

 

 

 

 

 

              else if (day < 23) place=68;

 

 

 

              else if (day < 30) place=71;

 

 

 

              else place=7}

 

 

 

}

 

 

 

      

 

 

 

       var pro; pro=p1+p2;

 

 

 

 

 

 

 

       msgWindow.document.write(" 在你的上一俗世生命之中" + "<BR>");

 

 

 

      

 

 

 

       //msgWindow.document.write("month=" + cur_month + " place=" + place + " ys=" + ys + " pro=" + pro + "<BR>");

 

 

 

 

 

 

 

      

 

 

 

       //countries data

 

 

 

       var countryString="";

 

 

 

       if (place == 1) countryString="今美国阿拉斯加洲(Alaska";

       else if (place == 2) countryString="今北美洲育空河流域(YUKON";

       else if (place == 3) countryString="今加拿大北部(North Canada";

       else if (place == 4) countryString="今北美安大略湖区(Ontario";

       else if (place == 5) countryString="今加拿大魁北克地区(Quebeck";

       else if (place == 6) countryString="今黎巴嫩境内(Labrador";

       else if (place == 7) countryString="今纽芬兰地区(Newfoundland";

       else if (place == 8) countryString="今格陵兰岛(Greenland";

       else if (place == 9) countryString="今美国西北部(USA North-West";

       else if (place == 10) countryString="今美国西南部(USA South-West";

       else if (place == 11) countryString="今美国中北部(USA North-Center";

       else if (place == 12) countryString="今美国中南部(USA South-Center";

       else if (place == 13) countryString="今美国东北部(USA North-East";

       else if (place == 14) countryString="今美国东南部(USA South-East";

       else if (place == 15) countryString="今美国阿肯色洲(Arkansas";

       else if (place == 16) countryString="今苏格兰地区(Scotland";

       else if (place == 17) countryString="今英国北部(Northern England";

       else if (place == 18) countryString="今英国中部(Central England";

       else if (place == 19) countryString="今英国南部(Southern England";

       else if (place == 20) countryString="今威尔士地区(Wales";

       else if (place == 21) countryString="今冰岛(Ireland";

       else if (place == 22) countryString="今欧洲北部(North Europe";

       else if (place == 23) countryString="今法国(France";

       else if (place == 24) countryString="今西班牙(Spain";

       else if (place == 25) countryString="今葡萄牙(Portugal";

       else if (place == 26) countryString="今奥地利(Austria";

       else if (place == 27) countryString="今德国(Germany";

       else if (place == 28) countryString="今乌克兰(Ukraine";

       else if (place == 29) countryString="今意大利(Italy";

       else if (place == 30) countryString="今土耳其(Turkey";

       else if (place == 31) countryString="今俄罗斯西部(West Russia";

       else if (place == 32) countryString="今西伯利亚(Siberia";

       else if (place == 33) countryString="今俄罗斯中部(Center Russia";

       else if (place == 34) countryString="今希腊(Greece";

       else if (place == 35) countryString="今伊朗(Iran";

       else if (place == 36) countryString="今沙特阿拉伯(Saudi Arabia";

       else if (place == 37) countryString="今波兰(Poland";

       else if (place == 38) countryString="今匈牙利(Hungary";

       else if (place == 39) countryString="今南斯拉夫(Yugoslavia";

       else if (place == 40) countryString="今罗马尼亚(Romania";

       else if (place == 41) countryString="今保加利亚(Bulgaria";

       else if (place == 42) countryString="今伊兹米尔(Izmir";

       else if (place == 43) countryString="今西藏(Tibet";

       else if (place == 44) countryString="今缅甸(Burma";

       else if (place == 45) countryString="今泰国(Thailand";

       else if (place == 46) countryString="今中国南部(South China";

       else if (place == 47) countryString="今蒙古(Mongolia";

       else if (place == 48) countryString="今中国北部(North China";

       else if (place == 49) countryString="今朝鲜(Korea";

       else if (place == 50) countryString="今日本北部(North Japan";

       else if (place == 51) countryString="今日本南部(South Japan";

       else if (place == 52) countryString="今苏门答腊(Sumatra";

       else if (place == 53) countryString="今婆罗洲(Borneo";

       else if (place == 54) countryString="今菲律宾(Filippines";

       else if (place == 55) countryString="今新圭亚那(New Guinea";

       else if (place == 56) countryString="今澳洲北部(North Australia";

       else if (place == 57) countryString="今澳洲西部(West Australia";

       else if (place == 58) countryString="今澳洲东部(East Australia";

       else if (place == 59) countryString="今澳洲南部(South Australia";

       else if (place == 60) countryString="今新西兰北部(North New Zealand";

       else if (place == 61) countryString="今新西兰南部(South New Zealand";

       else if (place == 62) countryString="今大洋州地区(Oceania";

       else if (place == 63) countryString="今印度北部(North India";

       else if (place == 64) countryString="今印度中部(Central India";

       else if (place == 65) countryString="今印度南部(South India";

       else if (place == 66) countryString="今埃及(Egypt";

       else if (place == 67) countryString="今非洲北部(North Africa";

       else if (place == 68) countryString="今非洲西部(West Africa";

       else if (place == 69) countryString="今非洲中部(Central Africa";

       else if (place == 70) countryString="今非洲南部(South Africa";

       else if (place == 71) countryString="今墨西哥(Mexico";

       else if (place == 72) countryString="今塞浦路斯(Cyprus";

       else if (place == 73) countryString="今拉美北部(North of Latin America";

       else countryString="今拉美南部(South of Latin America";

 

 

 

 

 

 

       //year of past life calculation

 

 

 

      

 

 

 

       var ys1;

 

 

 

 

 

 

 

            if (ys == "M") var mString = "185014001125102507000700180014751800130011751100";

 

 

 

       else if (ys == "N") var mString = "092518750425185017501350080006750825182515250875";

 

 

 

       else if (ys == "O") var mString = "172516750875070013251825177508001075165009001625";

 

 

 

       else if (ys == "P") var mString = "145005001800100008000550165017001325072511001550";

 

 

 

       else if (ys == "Q") var mString = "100014500950042517001525135011001625122517251025";

 

 

 

       else if (ys == "R") var mString = "097513751200127504500825137513500700092509250725";

 

 

 

       else if (ys == "S") var mString = "122506251250142509251150147507501300157506001125";

 

 

 

       else if (ys == "T") var mString = "117514001825127517500975185011501600187515251850";

 

 

 

       else if (ys == "U") var mString = "090009000775105013751675107515000825072510251500";

 

 

 

       else if (ys == "V") var mString = "122507501825140011501325167512751475160009501200";

 

 

 

       else if (ys == "W") var mString = "057516750775047517001450085017251775102517750400";

 

 

 

       else if (ys == "X") var mString = "180015751425157515501200160012001300037507751250";

 

 

 

       else if (ys == "Y") var mString = "107512501000165009501825155014250800175010750875";

 

 

 

       else                    var mString = "097505251175085015751125177513500700065013501050";

 

 

 

      

 

 

 

       ys1 = mString.charAt((cur_month-1)*4);

 

 

 

       if (ys1 == "0") ys1 = ""; {

 

 

 

       ys1 += mString.charAt((cur_month-1)*4+1);

 

 

 

              ys1 += mString.charAt((cur_month-1)*4+2); ys1 += mString.charAt((cur_month-1)*4+3)} ;

 

 

 

             

 

 

 

       //past life profession

 

 

 

 

 

 

 

if (pro == "A1") var proString = "挖土匠,挑夫";

       else if (pro == "A2") var proString = "哲学家, 思想家";

       else if (pro == "A3") var proString = "设计师, 工程师, 工匠";

       else if (pro == "A4") var proString = "化学家, 炼金术者, 药剂师";

       else if (pro == "A5") var proString = "水手, 厨师, 木匠";

       else if (pro == "A6") var proString = "珠宝制造商, 钟表制造商";

       else if (pro == "A7") var proString = "医师, 外科医生, 草药医生";

       else if (pro == "C1") var proString = "牧羊人, 马术师, 护林人";

       else if (pro == "C2") var proString = "领导者, 元首, 领袖";

       else if (pro == "C3") var proString = "图书管理员, 牧师, 遗迹看护人";

       else if (pro == "C4") var proString = "船长, 音乐家, 诗人, 祭祀师";

       else if (pro == "C5") var proString = "船员, 经销商, 商人, 经纪人";

       else if (pro == "C6") var proString = "僧侣, 养蜂人, 游侠";

       else if (pro == "C7") var proString = "作家, 剧作家, 祭祀住持";

       else if (pro == "B1") var proString = "修路者, 建桥者, 码头工";

       else if (pro == "B2") var proString = "制图员, 占星家, 天文学家";

       else if (pro == "B3") var proString = "工匠, 机械师";

       else if (pro == "B4") var proString = "勇士, 猎手, 渔夫, 刽子手";

else if (pro == "B5") var proString = "艺术家, 魔术师,富有者,出纳员";

       else if (pro == "B6") var proString = "水手, 皮鞋匠";

       else if (pro == "B7") var proString = "建造工人, 庙僧, 修士";

       else if (pro == "D1") var proString = "教练, 训兽员, 昆虫学家";

       else if (pro == "D2") var proString = "传道者, 发行人, 三流画家,书记员";

       else if (pro == "D3") var proString = "农夫, 纺织工, 裁缝";

       else if (pro == "D4") var proString = "剧作家,指挥家,音乐家, 吟游诗人";

       else if (pro == "D5") var proString = "银行家, 高利贷者, 旅行家, 法官";

       else if (pro == "D6") var proString = "教师, 数学家, 地质学家";

       else var proString = "舞蹈家, 歌唱家, 演员";

 

 

      

 

 

 

       //characteristics

 

 

 

 

 

 

 

       if (p2 == 1) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "你具有强大的组织能力和管理能力。善待你自己,如果不是一个自暴自弃者,否则可以成为独立的领导者。";

 

 

 

              else var charString = "你具有革新精神。可以涉猎多种领域——从政、从商、宗教、家政,你都能成为领导者。"

 

 

 

              };

 

 

 

       else if (p2 == 2) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "独特的艺术个性,你总可以在美丽与丑陋、灰暗和明亮之中来去自由。但你会在任何地点用任何方式表现自己。";

 

 

 

              else var charString = "有点胆小,有点反叛,有点沉静。但你有天才的创造力。直到个性被解放的那一天,否则将归于偏执。"

 

 

 

              };

 

 

 

 

 

 

 

       else if (p2 == 3) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "对事实有细微的观察和深入的思索。你能看到前途的方向,并作为理想主义者寻找实现未来的路径。";

 

 

 

              else var charString = "你总喜欢旅行、调查,不甘于平静,具有较强的侦探和观察能力。"

 

 

 

              };

 

 

 

 

 

 

 

       else if (p2 == 4) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "你理智,是实际的人。唯物主义,绝无唯心意识。能用简单的智慧化解烦劳和困难。";

 

 

 

              else var charString = "你总喜欢旅行、调查,不甘于平静,具有较强的侦探和观察能力。"

 

 

 

              };

 

 

 

 

 

 

 

       else if (p2 == 5) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "波希米亚人个性,神秘的,高智慧,能了解远古文化,魔术家能力,能受黑暗仆人的驱使。";

 

 

 

              else var charString = "自然的天才,心理学者,你知道如何应用机会,在任何情况下平息心境。"

 

 

 

              };

 

 

 

 

 

 

 

       else if (p2 == 6) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "好奇的,有创造性的,喜欢个性。戏剧化,是天然自成的表演者。"     

 

 

 

              else var charString = "这样的人喜欢多变,爱好一切新鲜事物。尤其在艺术,音乐,烹饪上。"

 

 

 

              };

 

 

 

 

 

 

 

       else if (p2 == 7) {

 

 

 

              if (place-2*(parseInt(place/2)) > 0) var charString = "你有头脑,科学者,总在查找新解释,新答案,受到环境误解,但都会尊重你的学识。";

 

 

 

              else var charString = "无情人物。在决定重大情形前,有克制力,不将就,会受人喜欢,但不经常爱。"

 

 

 

              };

 

 

 

 

 

 

 

       // past life lesson

 

 

 

 

 

 

 

       if (p2 == 1){

 

 

 

                   if (day < 12) var lesString = "力图改变环境的污染,致力于再生、可回收材料,通过各种渠道包括心理学方法消除放射性事物。";

 

 

 

              else if (day < 22) var lesString = "你学习进取,谦逊。自信精神上的原则,你应该为自己的信仰找到理由。";

 

 

 

                           else  var lesString = "你努力学习。了解其他人和在生命中遇到的困难,并喜欢帮助他们,给他们带来高兴的精神。"};

 

 

 

       else if (p2 == 2) {

 

 

 

                   if (day < 12) var lesString = "它总是象是你,那个世界于你的知觉有几分不同。你要相信你的直觉,最好接受它的指导。";

 

 

 

              else if (day < 22) var lesString = "它主持世界,制作世间更多的美丽,物理的和飘灵的沙漠荒芜都只是你的幻觉。保持乐观!";

 

 

 

                            else var lesString = "你的主力在于馈赠、开发宽宏大量和手足情谊。试着更少坚持己见,个性与学习一样多。当然你可以后退。"};

 

 

 

       else if (p2 == 3) {

 

 

 

                   if (day < 12) var lesString = "你要保持亲切。态度适人,表达理解,赠送同情的礼物。";

 

 

 

              else if (day < 22) var lesString = "你要发展心智,扩充意识,找到好老师。花费你的时间和部分能量分享他的智慧。";

 

 

 

                            else var lesString = "你要帮助旧友和孩子,你关心生命的学习和无助的心灵。"};

 

 

 

       else if (p2 == 4) {

 

 

 

                   if (day < 12) var lesString = "你应该敞开你的天才,成为爱、快乐和狂热的天使。把这些感觉分配给所有人。";

 

 

 

              else if (day < 22) var lesString = "你应该施与自信和自爱,让希望嵌进每个人的心。野心不是真的,真实的富有是埋葬你的灵魂。";

 

 

 

                            else var lesString = "你要征服嫉妒,寻找愤怒的背后。谁将选择你作为他们的指导,你应该了解这些虚弱导致的害怕会带来自己的遗憾。"};

 

 

 

       else if (p2 == 5) {

 

 

 

                   if (day < 12) var lesString = "你询问—学习,信任爱和天地,你一定想研究、回答,开发内部的智慧。";

 

 

 

              else if (day < 22) var lesString = "你有问题和学习的决心,将不幸撞碎在你强有力的臂膀上。";

 

 

 

                            else var lesString = "胆小,委琐,孤单,有自信的人,随时克服这些倾向,然后帮助他人。"};

 

 

 

       else if (p2 == 6) {

 

 

 

                   if (day < 12) var lesString = "世界充满疾病和孤单的人,你应该帮助那些比你更不幸的人。";

 

 

 

              else if (day < 22) var lesString = "有看不见的联系在物质与精神之间,你要一一寻找,找到它并应用这座桥。";

 

 

 

                            else var lesString = "你要慎重学习,然后教导其他。你的生命将更快乐,你的帮助从来都不缺道理。"};

 

 

 

       else if (p2 == 7) {

 

 

 

                   if (day < 12) var lesString = "你研究实践和应用的智慧,被附上了心灵的科学。并在远古手稿、强壮的信任和艰苦的工作中达到你现实命运的重生。";

 

 

 

              else if (day < 22) var lesString = "你在暴力和不和谐的世界真,了解它的起源,寻找她们的相似。";

 

 

 

                            else var lesString = "奇妙的是无论你在哪里,最通常和最平常的事是你让人们了解清楚的真相。你是伟大的魔术师!"};         

 

 

 

                           

 

 

 

       //message composition

 

 

 

 

 

 

 

       msgWindow.document.write("你曾出生在下列现代人居住区附近 " + countryString.fontcolor("yellow"));

 

 

 

       msgWindow.document.write(" 距今大约 " + ys1.fontcolor("yellow") + ".<BR>");

 

 

 

       msgWindow.document.write("你的职业曾是 " + proString.fontcolor("yellow") + ".<BR>");

 

 

 

       msgWindow.document.write("下面是有关你上一俗世生命的心理摘要:<BR>" + charString.fontcolor("yellow") + "<BR>");

 

 

 

       msgWindow.document.write("教训——来自上一俗世生命对你的馈赠:<BR>" + lesString.fontcolor("yellow") + "<BR></FONT> ");

 

 

 

       msgWindow.document.write("<FONT FACE=Arial Color=red><B><I>" + "So,现在你感觉如何?" + "</I></B><BR><BR></FONT>");

//

}

</SCRIPT>

 

<P><font color="#000000">有人说,每个人都有过去的生命。那么,你想知道自己的过去生命是谁吗?</font></P>

 

<P><font color="#000000">方法很简单,填入自己的生辰年月日,然后单击下面按钮</font></P>

 

<P><font color="#000000">剩下的事情就由我来告诉你吧。</font></P>

<p><font color=blue>(注意:请把三个空都填完整,否则会产生脚本错误!!)</font></p>

 

<P></CENTER>

 

<FORM NAME = "Past Life">

 

<CENTER>

<PRE><B>出生日:</B> <INPUT TYPE="num" name="day" onChange="if (!checkNum(this.value, 1, 31)){this.focus();this.select();} else {}" size=2 value="">   <b>出生月</b><B>:</B> <INPUT TYPE="num" name="month" onChange="if (!checkNum(this.value, 1, 12)){this.focus();this.select();} else {}" size=2 value="">  <B>出生年(样例:78:</B> <INPUT TYPE="num" name="year" onChange="if (!checkNum(this.value, 0, 99)){this.focus();this.select();} else {}" size=2 value=""></PRE>

 

<INPUT TYPE="button" name="Find_Out" value="天灵灵!地灵灵!呵呵.." onclick="pastlife(this.form)">

</FORM>

 

1 Comments

Fri

20

Mar

2009

91、一段文字游戏

91、一段文字游戏

脚本说明:

把如下代码加入<body>区域中

<TABLE cellSpacing=0 cellPadding=4 width=468 border=0>

<TBODY>

<TR>

<TD vAlign=top align=left width=468 bgColor=pink>

<P align=center><FONT face=宋体><SPAN class=font><FONT

color=#4f76d5>一个好玩的东东</FONT></SPAN></FONT></P></TD></TR></TBODY></TABLE>

<TABLE cellSpacing=0 cellPadding=4 width=468 border=0>

<TBODY>

<TR>

<TD vAlign=top align=left width=468>

<P align=left><FONT face=宋体><SPAN class=font>

<SCRIPT language=JavaScript>

         <!-- ;

 

         alert("照着屏幕上说的写,可不要乱写,不然的话你会后悔的!");

         // end hide --></SCRIPT>

一个

<SCRIPT><!-- iniciar

         var WEATHER = prompt("输入你最喜欢的气候","")

         document.write(" " + WEATHER + " ") // finalizar --></SCRIPT>

的午後,你正在

<SCRIPT><!-- iniciar

         var PLACE1 = prompt("输入你最喜欢的地方","")

         document.write(" " + PLACE1 + " ")

         // finalizar --></SCRIPT>

愉快的

<SCRIPT><!-- iniciar

         var ACTN = prompt("输入你最喜欢作的事","")

         document.write(" " + ACTN + " ")

         // finalizar --></SCRIPT>

时,你看到了一个世上最

<SCRIPT><!-- iniciar

         var ADJ1 = prompt("输入一个词形容你喜欢的异性","")

         document.write(" " + ADJ1 + " ")

         // finalizar --></SCRIPT>

的人。

<SCRIPT><!-- iniciar

         var SEX = prompt("你所喜欢的是''还是''?","")

         document.write(" " + SEX + " ")

         // finalizar --></SCRIPT>

叫做

<SCRIPT><!-- iniciar

         var NAME1 = prompt("输入你所喜欢异性的名字","")

         document.write(" " + NAME1 + " ")

         // finalizar --></SCRIPT>

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")

         // finalizar --></SCRIPT>

的每个动作都十分吸引你,於是你对你的好朋友

<SCRIPT><!-- iniciar

         var NAME2 = prompt("输入你好朋友的名字","")

         document.write(" " + NAME2 + " ")

         // finalizar --></SCRIPT>

: "看那边! 那是我看过最

<SCRIPT><!-- iniciar

         var ADJ3 = prompt("输入一个形容词","")

         document.write(" " + ADJ3 + " ")

         // finalizar --></SCRIPT>

的人了!" 突然间,

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")

         // finalizar --></SCRIPT>

向你这边看了一眼并开始朝你走过来!!!

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")

         // finalizar --></SCRIPT>

: "我早就发现你在偷偷看我了。说实话,我觉得你满

<SCRIPT><!-- iniciar

         var ADJ4 = prompt("输入一个词形容你自己","")

         document.write(" " + ADJ4 + " ")

         // finalizar --></SCRIPT>

的。你愿意跟我去

<SCRIPT><!-- iniciar

         var PLACE2 = prompt("输入另一个你喜欢的地方","")

         document.write(" " + PLACE2 + " ")

         // finalizar --></SCRIPT>

然後一起

<SCRIPT><!-- iniciar

         document.write(" " + ACTN + " ")

         // finalizar --></SCRIPT>

?" 你露出了一个兴奋的微笑并说 : "

<SCRIPT><!-- iniciar

         var PHRASE = prompt("输入一个你认为最酷的话","")

         document.write(" " + PHRASE + " ")

         // finalizar --></SCRIPT>

" 便一起走了。当你们到达

<SCRIPT><!-- iniciar

         document.write(" " + PLACE2 + " ")

         // finalizar --></SCRIPT>

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")

         // finalizar --></SCRIPT>

突然移进你并在你的脸颊上温柔的亲了一下。当你正陶醉在其中时,一个

<SCRIPT><!-- iniciar

         var NOUN = prompt("输入在你房间有的东西","")

         document.write(" " +NOUN+ " ")

         // finalizar --></SCRIPT>

重重的打在你的头上。你睁开眼,发现原来只是个梦,但是你在身旁发现了一个纸条写道 : "

<SCRIPT><!-- iniciar

         document.write(" " + NAME1 + " ")

         // finalizar --></SCRIPT>

是你的最爱。

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")       // finalizar --></SCRIPT>

将会问你是否愿意和

<SCRIPT><!-- iniciar

         document.write(" " + SEX + " ")       // finalizar --></SCRIPT>

交往。 但你必须在

<SCRIPT><!-- iniciar

         var NUM = prompt("输入你的幸运号码","")

         document.write(" " + NUM + " ")

         // finalizar --></SCRIPT>

天以内带10个人以上来,不然你将会有

<SCRIPT><!-- iniciar

         document.write(" " + NUM + " ")

         // finalizar --></SCRIPT>

年的厄运!!" </SPAN></FONT></P>

</TBODY></TABLE>

 

0 Comments