Gossamer Forum
Home : Gossamer Threads Inc. : Discussion :

suggestion for GT::URI

Quote Reply
suggestion for GT::URI

In GT::URI::get, could something like the following be added, or am I oversimplifying thing?
if( $url =~ /^https/ ) {
my $r->{$url}{buffer} = GT::URI::HTTPS->get($url);
return $r;
} else {
return GT::URI->get( $url );

To summarize: it would be nice if I don't have to decide whether to call GT::URI::get() or GT::URI::HTTPS::get() myself. And it would be nice if both functions return their result in the same structure (or if at least it would be documented what is returned).

Thanks, Jasper

Quote Reply
Re: [jaspercram] suggestion for GT::URI In reply to
Hi Jasper,

I've written a replacement, GT::WWW, which should start appearing with our programs sometime soon and makes GT::URI obselete. It's designed to be a much more generic module, with standardized and less complex (but more complete) return values. It currently supports HTTP and HTTPS, including GET and POST support, the ability to handle file uploads, basic HTTP authentication, and gzip/deflate transfer support (if Compress::Zlib is available) to name a few.

Jason Rhinelander
Gossamer Threads
Quote Reply
Re: [Jagerman] suggestion for GT::URI In reply to
Any idea when you will publish it?