?? modifysubareainput.jsp
字號:
<!-- 系統名稱:光大花園物業管理系統 -->
<!-- 程序名稱:ModifySubAreaInput.jsp -->
<!-- 程序類型:jsp文件 -->
<!-- 功能簡述:修改分區資料輸入頁面 -->
<!-- 作 者:韓立鋒 -->
<!-- 公 司:長春中聯 -->
<!-- 完成時間:2001/08/24 -->
<!-- 修 改 人:畢鋒 -->
<!-- 修改內容:頁面 -->
<!-- 修改時間:2001/11/28 -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" type="text/css" href="/pmsApp/css/wuye.css">
<title>資料管理-修改分區資料數據</title>
<script language="JavaScript" src="/pmsApp/common/wuye.js"></script>
<script language="JavaScript" src="/pmsApp/common/admin.js"></script>
<%
String number1=(String)request.getParameter("number");
String subareanumb=(String)request.getParameter("subareanumb");
String subareaname=(String)request.getParameter("subareaname");
String subareadescribe=(String)request.getParameter("subareadescribe");
String path=(String)request.getParameter("path");System.out.println("path="+path);
String publicservice=(String)request.getParameter("publicservice");System.out.println("publicservice="+publicservice);
String hirerate=(String)request.getParameter("hirerate");System.out.println("hirerate="+hirerate);
String salerate=(String)request.getParameter("salerate");System.out.println("salerate="+salerate);
String firefighting=(String)request.getParameter("firefighting");System.out.println("firefighting="+firefighting);
String security=(String)request.getParameter("security");System.out.println("security="+security);
String remark=(String)request.getParameter("remark");System.out.println("remark="+remark);
String tmp1 = subareadescribe;
int index1 = 0;
index1=tmp1.indexOf("<br>");
while (index1!=-1){
tmp1 = tmp1.substring(0,index1)+"\n"+tmp1.substring(index1+4,tmp1.length());
index1=tmp1.indexOf("<br>");
}
subareadescribe=tmp1;
String tmp2 = path;
int index2 = 0;
index2=tmp2.indexOf("<br>");
while (index2!=-1){
tmp2 = tmp2.substring(0,index2)+"\n"+tmp2.substring(index2+4,tmp2.length());
index2=tmp2.indexOf("<br>");
}
path=tmp2;
String tmp3 = publicservice;
int index3 = 0;
index3=tmp3.indexOf("<br>");
while (index3!=-1){
tmp3 = tmp3.substring(0,index3)+"\n"+tmp3.substring(index3+4,tmp3.length());
index3=tmp3.indexOf("<br>");
}
publicservice=tmp3;
String tmp4 = firefighting;
int index4 = 0;
index4=tmp4.indexOf("<br>");
while (index4!=-1){
tmp4 = tmp4.substring(0,index4)+"\n"+tmp4.substring(index4+4,tmp4.length());
index4=tmp4.indexOf("<br>");
}
firefighting=tmp4;
String tmp5 = security;
int index5 = 0;
index5=tmp5.indexOf("<br>");
while (index5!=-1){
tmp5 = tmp5.substring(0,index5)+"\n"+tmp5.substring(index5+4,tmp5.length());
index5=tmp5.indexOf("<br>");
}
security=tmp5;
String tmp6 = remark;
int index6 = 0;
index6=tmp6.indexOf("<br>");
while (index6!=-1){
tmp6 = tmp6.substring(0,index6)+"\n"+tmp6.substring(index6+4,tmp6.length());
index6=tmp6.indexOf("<br>");
}
remark=tmp6;
int filesize = Integer.parseInt(request.getParameter("size"));
%>
<script language="JavaScript">
<!--
function MM_swapImgRestore() {// v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() {// v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) {// v4.0
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && document.getElementById) x=document.getElementById(n); return x;
}
function MM_swapImage() {// v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function JustSoPicWindow(imageName,imageWidth,imageHeight,alt,bgcolor,hugger) {
// by E Michael Brandt of ValleyWebDesigns.com - Please leave this comment intact.
alt=alt+" ** Click window to close **"
if (bgcolor=="") {
bgcolor="#FFFFFF";
}
var adj=10
var w = screen.width;
var h = screen.height;
var byFactor=1;
if(w<740){
var lift=0.90;
}
if(w>=740 & w<835){
var lift=0.91;
}
if(w>=835){
var lift=0.93;
}
if (imageWidth>w){
byFactor = w / imageWidth;
imageWidth = w;
imageHeight = imageHeight * byFactor;
}
if (imageHeight>h-adj){
byFactor = h / imageHeight;
imageWidth = (imageWidth * byFactor);
imageHeight = h;
}
var scrWidth = w-adj;
var scrHeight = (h*lift)-adj;
if (imageHeight>scrHeight){
imageHeight=imageHeight*lift;
imageWidth=imageWidth*lift;
}
var posLeft=0
var posTop=0
if (hugger=="hug image") {
posTop = (scrHeight-imageHeight)/2;
posLeft = ((w-imageWidth)/2);
scrHeight = imageHeight-adj;
scrWidth = imageWidth-adj;
}
imageHeight=imageHeight-adj;
imageWidth=imageWidth-adj;
newWindow = window.open("","newWindow","width="+scrWidth+",height="+scrHeight+",left="+posLeft+",top="+posTop);
newWindow.document.open();
newWindow.document.write('<html><title>'+alt+'</title><body leftmargin="0" topmargin="0" marginheight="0" marginwidth="0" bgcolor='+bgcolor+' onBlur="self.close()" onClick="self.close()">');
newWindow.document.write('<table width='+imageWidth+' border="0" cellspacing="0" cellpadding="0" align="center" height='+scrHeight+' ><tr><td>');
newWindow.document.write('<img src='+imageName+' width='+imageWidth+' height='+imageHeight+' alt=\"Click\ \;screen\ \;to\ \;close.\" >');
newWindow.document.write('</td></tr></table></body></html>');
newWindow.document.close();
newWindow.focus();
}
//-->
//檢驗百分數的合法性
function Chkhirerate(num)
{
for(i_loop=0;i_loop<=88;i_loop++) {
if (!(num.charAt(i_loop)=='.'))
if (!((num.charAt(i_loop)>=0)&&(num.charAt(i_loop)<=9)))
{
return false ;
}
}
return true;
}
function ChkDigit3(num)
{
for(i_loop=0;i_loop<num.length;i_loop++)
{
if (!(((num.charAt(i_loop)>=0)&&(num.charAt(i_loop)<=9))||(num.charAt(i_loop)=="%")))
{
return false ;
}
}
}
//判斷是否含有非法字符
function ChkUnvialble(num){
for(i=0;i<num.length;i++){
if(!((num.charAt(i)>=0)&&(num.charAt(i)<=9))&&(!((num.charAt(i)>="a")&&(num.charAt(i)<="z")))&&(!((num.charAt(i)>="A")&&(num.charAt(i)<="Z"))))
{
return false;
}
}
}
function CheckForm(inputForm)
{
Nvoid(inputForm);
if (inputForm.subareanumb.value==""){
alert("請輸入分區編號");
inputForm.subareanumb.focus();
return false;
}
if (inputForm.subareanumb.value.length>2){
alert("分區編號不能大于2位");
inputForm.subareanumb.focus();
return false;
}
if(ChkUnvialble(inputForm.subareanumb.value)==false){
alert("分區編號不能是非法字符,只能是數字或者英文字母!");
inputForm.subareanumb.focus();
return false;
}
if (inputForm.subareadescribe.value.length>500){
alert("分區簡介不能超過500個字");
inputForm.subareadescribe.focus();
return false;
}
if (inputForm.path.value.length>25){
alert("公交路線不能超過25個字");
inputForm.path.focus();
return false;
}
if (inputForm.publicservice.value.length>50){
alert("公用設施不能超過50個字");
inputForm.publicservice.focus();
return false;
}
if (inputForm.hirerate.value!="") {
var len=0;
for (i=0;i<inputForm.hirerate.value.length;i++) {
if (inputForm.hirerate.value.charAt(i)=='.')
len++;
}
if (len==1) {
if (inputForm.hirerate.value.length<2) {
alert("輸入的出租率不正確");
inputForm.hirerate.select();
return false;
}
var ss = inputForm.hirerate.value;
var subLen = ss.substring(ss.indexOf(".")+1);//得到小數點后面的位數
if (subLen.length>2) {
alert("輸入的出租率不正確,小數點后最多只有兩位!");
inputForm.hirerate.select();
return false;
}
}
if (len>1) {
alert("輸入的出租率不正確");
inputForm.hirerate.select();
return false;
}
if (Chkhirerate(inputForm.hirerate.value)==false) {
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -