Ash Rai has asked for the wisdom of the Perl Monks concerning the following question:
sub __mechanize_http { $win = @_; $title = $win->{titleTxt}->GetValue(); #$win is the main window and +titleTxt is the name of one of the text field. GetValue() will return + the content of text field in WxString fromat. $commentfile = $win->{fileNameTxt}->GetValue(); #Wx::TextCtrl->GetValue() returns WxString. print "\nTitle: ",$title; print "\nOutput: ", $commentfile; my $url = "http://www.example.com/"; my $mech = WWW::Mechanize->new(autocheck => 1); $mech->agent_alias ( "Windows IE 6" ); $mech->get($url) or die "Can't even get $url: " . $mech->response->status_line unless ($mech->success); $mech->form_name('AddForm'); $mech->field(title => $title); $mech->field(commentfile => $commentfile); $mech->submit(); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Question on WxString (WxPerl) and WWW::Mechanize
by b4swine (Pilgrim) on Sep 11, 2007 at 01:16 UTC | |
by Ash Rai (Acolyte) on Sep 11, 2007 at 15:03 UTC | |
|
Re: Question on WxString (WxPerl) and WWW::Mechanize
by Anonymous Monk on Sep 11, 2007 at 07:49 UTC | |
by Ash Rai (Acolyte) on Sep 11, 2007 at 15:05 UTC | |
by Ash Rai (Acolyte) on Sep 12, 2007 at 17:44 UTC |