문제

In Perl WWW:Mechanize would a

$mech->get($url) 

and a

$mech->post($url, [ 'field' => "$var"]);

command run on the same or separate instances of a page?

I'm looking up values of form/field IDs and using them to generate the POST command, but it's working.

도움이 되었습니까?

해결책

HTTP is a stateless protocol. Every request is independent of any other, so there are no "instances" of a page.

It is possible to create sessions by tying requests together using cookies, but from what you've told us that is irrelevant here.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top