delphi
文章平均质量分 68
扬州老农
这个作者很懒,什么都没留下…
展开
-
IP地址物理位置查询,支持IPV6
其实很简单,通过公开的查询接口获取JSON,解析即可。 IPV4: CX_URL := 'http://whois.pconline.com.cn/ipJson.jsp?json=true&ip='; try JSONStr := form1.IdHTTP1.Get(CX_URL + ipv4); if JSONStr <> '' then begin aJson:=TJSONObject.ParseJSONValue(Trim(JSONStr)) as TJS...原创 2021-09-13 16:25:38 · 490 阅读 · 0 评论 -
身份证号码校验位的计算方法
Delphi例子: function jy_sfzh(Str:string):char; var r:integer; t_tmp:integer; jym:char; begin if (isnum(copy(Str,1,17))=true) and (isdate(copy(Str,7,8))=true) then begin t_tmp:=(strtoint(Str[1])*7 +strtoint(Str[2])*9 +strtoint(Str[3])...原创 2021-09-13 15:46:04 · 422 阅读 · 0 评论