Automatically send and receive data from an HTML page

I am not sure which module I should use for this. I have> 100 files that need to be sent to the next web page and get the results.

http://bip.weizmann.ac.il/oca-bin/lpccsu

It would be useful if I could automate the process, somehow sending the file to

'<'input type="file" name="filename"  size='30''>'

and then get the returned html so that it can be processed using regular expressions.

thank

edit to see sample output, set radioobutton to CSU and type 1eo8 in the "PDB entry" text box

+3
source share
2 answers

@Anake Here are 3 Pythonic packages that provide a solution for extraction and analysis:

From their websites:

, , . " " " externalLink" " , URL- " foo.com ", " , , . " 1

- Python Andy Lesters Perl 2

Scrapy - - , - . : . 3

+2

:

1) Perl LWP

use LWP::UserAgent; 
my $ua = new LWP::UserAgent; 

my $response 
= $ua->post('http://bip.weizmann.ac.il/oca-bin/lpccsu?9955', 
{ param1 => 'value1',
param2 => 'value2', 
}); 

my $content = $response->content;
// your regular expression code

2) Autohotkey, , , POST, . http://www.autohotkey.com/forum/topic33506.html

3) , wget -post-data -post , favortite script : http://www.gnu.org/software/wget/manual/html_node/HTTP-Options.html

,

+2

All Articles