perl lwp 默认的请求头
来源:互联网 发布:免费数据库有哪些 编辑:程序博客网 时间:2024/06/07 19:30
</pre><pre name="code" class="html">[root@dr-mysql01 ~]# cat getx.pl use LWP::UserAgent; $ua = LWP::UserAgent->new;# @header = (# 'accept'=> "application/json",# 'content-type'=> "application/json", #'apix-key'=> "e7b00871640c49567a37566ccd5c27e9", # 'User-Agent' => "Mozilla/8.0" # );$ua->agent('Mozilla/999.0');$host="http://zjcap.cn";$request = HTTP::Request->new(GET=>"$host");#$request->header(@header);use Data::Dumper;print Dumper($ua); my $hdrs = $request->headers;print Dumper($hdrs);[root@dr-mysql01 ~]# perl getx.pl $VAR1 = bless( { 'max_size' => undef, 'max_redirect' => 7, 'ssl_opts' => { 'verify_hostname' => 1 }, 'def_headers' => bless( { 'user-agent' => 'Mozilla/999.0' }, 'HTTP::Headers' ), 'no_proxy' => [], 'proxy' => {}, 'handlers' => { 'response_header' => bless( [ { 'line' => '/usr/local/perl/lib/site_perl/5.22.1/LWP/UserAgent.pm:684', 'callback' => sub { "DUMMY" }, 'm_media_type' => 'html', 'owner' => 'LWP::UserAgent::parse_head' } ], 'HTTP::Config' ) }, 'use_eval' => 1, 'show_progress' => undef, 'protocols_allowed' => undef, 'requests_redirectable' => [ 'GET', 'HEAD' ], 'local_address' => undef, 'timeout' => 180, 'protocols_forbidden' => undef }, 'LWP::UserAgent' );$VAR1 = bless( {}, 'HTTP::Headers' );
0 0
- perl lwp 默认的请求头
- perl lwp 获取请求头
- perl的LWP模块介绍
- Perl&LWP
- Perl & LWP
- PERL LWP
- perl中LWP模块的使用
- Perl中LWP模块的使用
- perl的LWP模块简单介绍
- perl的LWP模块简单介绍
- Perl LWP::Simple 提供的方法
- perl 自定义请求头
- perl 自定义请求头
- perl LWP 网络编程
- perl --- LWP::UserAgent
- perl and LWP 文档
- perl and LWP 文档
- perl&lwp经典用法
- In android studio,cannot load 2 facets-unknown facet type:android and android-gradle
- ios中修改状态栏颜色的方法
- 剑指offer(二.1)数据结构篇之数组
- Merge Intervals And Insert Interval -- Leetcode
- chrome Vimium plugin
- perl lwp 默认的请求头
- Eclipse无法以Debug模式运行
- JAX-RS入门 十二: 可伸缩的JAX-RS应用
- BZOJ 3122: [Sdoi2013]随机数生成器 ex_gcd+BSGS
- MySQL执行计划
- 解析xml文件的四种方式
- MySQL5.7.13源码编译安装与配置
- JAVA 读取本地配置文件;可执行的jar文件中配置文件的获取
- php创建自定义404页面