file upload

file upload

am 06.01.2007 22:44:23 von r.j.dobson

hi,


i'm trying to upload a couple of files using the following form:




To run a detailed ssSNPer
analysis on a single SNP:

Specify the location
of your file containing
the test SNP rs# (e.g., " href="http://fraser.qimr.edu.au/general/daleN/ssSNPer/rs1800 630snp.txt">rs1800630snp.txt"):



Specify the location of your HapMap SNP
genotype data dump file (e.g., " href="http://fraser.qimr.edu.au/general/daleN/ssSNPer/rs1800 630dumpedregion.txt">rs1800630dumpedregion.txt"):



Please be patient, our web server may be
busy and depending upon the size of your test region your query may take
a few minutes (the example files take ~90 seconds).








i'm using the following piece of code to submit:

#!/usr/bin/perl

use strict;
use LWP::UserAgent;
use WWW::Mechanize;
use HTML::Form;

my $ua = LWP::UserAgent->new;
my $response = $ua->get("http://fraser.qimr.edu.au/general/daleN/ssSNPer/") ;
my $form = HTML::Form->parse($response->decoded_content,
$response->base);
my @inputs = $form->inputs;

$inputs[0]->file( "/tmp/hapmap/rs1800630snp.txt " );
$inputs[1]->file( "/tmp/hapmap/rs1800630dumpedregion.txt" );

$ua = LWP::UserAgent->new;
$response = $ua->request($form->click);


my $content=$response->content;

print $content;



the error that I get in the $content states that the files failed to upload.



Any ideas?

Re: file upload

am 07.01.2007 14:33:47 von r.j.dobson

Quoting Richard Dobson :

whoops, had I read the docs better I would have seen http::request::common

cheers
Rich


>
> hi,
>
>
> i'm trying to upload a couple of files using the following form:
>
>
>


>


> To run a detailed ssSNPer
> analysis on a single SNP:

>

Specify the location
> of your file containing
> the test SNP rs# (e.g., " >
href="http://fraser.qimr.edu.au/general/daleN/ssSNPer/rs1800 630snp.txt">rs1800630snp.txt"):

>

>

Specify the location of your HapMap SNP
> genotype data dump file (e.g., " >
href="http://fraser.qimr.edu.au/general/daleN/ssSNPer/rs1800 630dumpedregion.txt">rs1800630dumpedregion.txt"):

>

>

Please be patient, our web server may be
> busy and depending upon the size of your test region your query may take
> a few minutes (the example files take ~90 seconds).

>

>
>


>
>
>
> i'm using the following piece of code to submit:
>
> #!/usr/bin/perl
>
> use strict;
> use LWP::UserAgent;
> use WWW::Mechanize;
> use HTML::Form;
>
> my $ua = LWP::UserAgent->new;
> my $response = $ua->get("http://fraser.qimr.edu.au/general/daleN/ssSNPer/") ;
> my $form = HTML::Form->parse($response->decoded_content,
> $response->base);
> my @inputs = $form->inputs;
>
> $inputs[0]->file( "/tmp/hapmap/rs1800630snp.txt " );
> $inputs[1]->file( "/tmp/hapmap/rs1800630dumpedregion.txt" );
>
> $ua = LWP::UserAgent->new;
> $response = $ua->request($form->click);
>
>
> my $content=$response->content;
>
> print $content;
>
>
>
> the error that I get in the $content states that the files failed to upload.
>
>
>
> Any ideas?
>
>