2017年3月21日星期二

Perl : 调用 Socket 接口 获取指定域名的IP

use Socket;
my $dom = 'www.google.com';
my $ip = inet_ntoa(inet_aton($dom));

没有评论:

发表评论