[求助]jsp问题,高手请进!!!急
function IP2Num(sip)dim str1,str2,str3,str4
dim num
IP2Num=0
if isnumeric(left(sip,2)) then
str1=left(sip,instr(sip,".")-1)
sip=mid(sip,instr(sip,".")+1)
str2=left(sip,instr(sip,".")-1)
sip=mid(sip,instr(sip,".")+1)
str3=left(sip,instr(sip,".")-1)
str4=mid(sip,instr(sip,".")+1)
num=cint(str1)*256*256*256+cint(str2)*256*256+cint(str3)*256+cint(str4)-1
IP2Num = num
end if
end function
上面这段代码是IP地址换算的asp程序,我想换成jsp的类方法,不是js的,请各位高手帮忙!!!
[此贴子已经被作者于2005-11-1 10:35:11编辑过]