yup, I tried as what you said. no luck indeed.
use HTTP::Cookies::Netscape;
my $cookie_jar = HTTP::Cookies::Netscape->new(
file => 'E:/lwp_cookies.dat',
autosave => 1,
);
my $mech = WWW::Mechanize->new(
agent => 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)',
cookie_jar => $cookie_jar,
stack_depth => 1,
autocheck => 1,
);
mm, we brought a script written by php. it uses 'curl_exec' and works fine. I tried to search in CPAN. and find WWW::Curl, but failed to install this module. (install progress stoped at test).
I just wonder whether anyone has written a similar script and give me a hint.
Thanks for your tip any way, inman.
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|