📄 bank.htm
字号:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<META HTTP-EQUIV="PRAGMA" CONTENT="CACHE">
<META HTTP-EQUIV="EXPIRES" CONTENT="TUE,04 Dec 2096 21:29:02 GMT">
<title>蓝雨聊天室(银行)</title>
<style type="text/css">
<!--
td, p, input, font, select, option, textarea, form { font-family:"宋体"; font-size: 12px }
a:link { text-decoration: none }
a:visited { text-decoration: none; color:#0000ff}
a:hover { text-decoration: underline }
a:active { text-decoration: none;}
.p9 {font-size: 9pt; line-height: 14pt }
-->
</style>
</head>
<script language="javascript">
var hasdoing=0;
var dotimer=0;
var isreguser=0;
var appletmark="";
function c_value(ename,evalue)
{
for(i=0; i<document.all.length; i++)
{
if(document.all(i).name==ename)
document.all(i).innerText=evalue;
}
}
function on_start()
{
appletmark=opener.document.ChatClient.getAppletMark();
var uname=opener.document.ChatClient.getMyName();
if(uname.length>0 && uname.substring(0,1)=="*")
{
isreguser=1;
uname=uname.substring(1);
}
var imoney=opener.document.ChatGame.getMoney();
var bmoney=opener.document.ChatClient.getBankMoney();
c_value("uname",uname);
c_value("umoney",imoney);
c_value("ubmoney",bmoney);
setInterval("window_timer()", 2000);
}
function window_timer()
{
var imoney=opener.document.ChatGame.getMoney();
var bmoney=opener.document.ChatClient.getBankMoney();
c_value("umoney",imoney);
c_value("ubmoney",bmoney);
var imark=opener.document.ChatClient.getSaveMoneyMark();
if(imark>0)
{
document.form1.savebtn.disabled="";
document.form1.getbtn.disabled="";
}
if(imark==1)
c_value("atitle","你提交的操作已完成,谢谢惠顾,欢迎下次光临!");
else if(imark==2)
c_value("atitle","很抱歉,不能完成你的操作。");
dotimer++;
}
function valid_num(str)
{
if(str.length<=0)
return false;
else if(str.substring(0,1)=='0')
return false;
Re=/\D/;
A1=Re.exec(str);
if(A1)
return false;
else
return true;
}
function save_money()
{
if(!checkWindow())
{
window.close();
return;
}
var mval=document.form1.savemoney.value;
if(isreguser==0)
alert("本银行不办理非注册用户的业务。");
else if(mval=="")
alert("请填写你要存的钱的数目。");
else if(!valid_num(mval))
alert("请填写正确的存款数字!不能有空格。");
else if(hasdoing==1 && dotimer<30)
alert("对不起,银行忙,请稍候再存。");
else if(opener.document.ChatClient.isZhuangJia()==1)
alert("对不起,你正在开庄,暂时不能存钱。");
else
{
var umoney=opener.document.ChatGame.getMoney();
c_value("umoney",umoney);
var imoney=eval(umoney);
var nmoney=eval(mval);
if(nmoney>imoney)
alert("你没有那么多现金可以存!");
else if(nmoney<100)
alert("存款的最小金额是100。");
else
{
hasdoing=1;
dotimer=0;
opener.document.ChatClient.changeBankMoney(""+nmoney);
c_value("atitle","正在办理你的存款(存"+nmoney+"元)业务,请稍候...");
document.form1.savemoney.value="";
document.form1.savebtn.disabled=true;
document.form1.getbtn.disabled=true;
}
}
}
function checkWindow()
{
if(appletmark=="" || appletmark!=opener.document.ChatClient.getAppletMark())
{
alert("本页面已经超时了,请重新打开窗口。");
return false;
}
else
return true;
}
function get_money()
{
if(!checkWindow())
{
window.close();
return;
}
var mval=document.form1.getmoney.value;
if(isreguser==0)
alert("本银行不办理非注册用户的业务。");
else if(mval=="")
alert("请填写你要取的钱的数目。");
else if(!valid_num(mval))
alert("请填写正确的取款数字!不能有空格。");
else if(hasdoing==1 && dotimer<30)
alert("对不起,银行忙,请稍候再取。");
else
{
var umoney=opener.document.ChatClient.getBankMoney();
c_value("ubmoney",umoney);
var imoney=eval(umoney);
var nmoney=eval(mval);
if(nmoney>imoney)
alert("你没有那么多存款可以取。");
else if(nmoney<100)
alert("取款的最小金额是100。");
else
{
hasdoing=1;
dotimer=0;
opener.document.ChatClient.changeBankMoney("-"+nmoney);
c_value("atitle","正在办理你的取款(取"+nmoney+"元)业务,请稍候...");
document.form1.getmoney.value="";
document.form1.savebtn.disabled=true;
document.form1.getbtn.disabled=true;
}
}
}
</script>
<body bgcolor="#C0C0C0" topmargin="5" leftmargin="5" onload="on_start()" oncontextmenu="self.event.returnValue=false">
<form name="form1">
<table border="2" width="100%" height="100%" bordercolor="#A5A5A5" bordercolorlight="#A5A5A5"
bordercolordark="#A5A5A5" cellspacing="0" cellpadding="5">
<tr>
<td width="100%" bgcolor="#C3C3C3" height="10%"><table border="0" width="100%">
<tr>
<td width="50%"><strong>天涯银行自动柜员机</strong></td>
<td width="50%" align="right"><input type="button" value="关闭窗口" onclick="window.close()"></td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="100%" bgcolor="#E2E2E4">
<table border="0" width="100%" height="50%">
<tr>
<td width="100%" colspan="2"> <strong><font color="#ff0000" name="atitle">欢迎光临天涯银行!存钱每天利息为:1%</font></stong><br><br></td>
</tr>
<tr>
<td width="20%">你的开户名:</td>
<td width="80%"><font color="#8000FF" name="uname"></font></td>
</tr>
<tr>
<td width="20%">你的现金:</td>
<td width="80%"><font color="#8000FF" name="umoney"></font> ¥</td>
</tr>
<tr>
<td width="20%">你的存款:</td>
<td width="80%"><font color="#8000FF" name="ubmoney"></font> ¥</td>
</tr>
<tr>
<td width="20%">存款:</td>
<td width="80%"><input type="text" name="savemoney" size="12" maxlength="12"><input type="button" value="存款" name="savebtn" onclick="save_money()"></td>
</tr>
<tr>
<td width="20%">取款:</td>
<td width="80%"><input type="text" name="getmoney" size="12" maxlength="12"><input type="button" value="取款" name="getbtn" onclick="get_money()"></td>
</tr>
</table>
<p><br>
<br>
</td>
</tr>
</table>
</form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -