satanklawz has asked for the wisdom of the Perl Monks concerning the following question:
Below is the code.... kVRFMNI"*#VZHF$2TPWPRj{#8HRW Xj L !.x + 2)C‹4Ts c"ىYv9+V 0VOi8>Z@)ki›nH& + ...
The question is does anyone know how to get the image to be relayed without having to be stored locally? I'm intentionally not using any scrict at the moment so that debugging is easier.#!/usr/bin/perl use CGI; use LWP; use LWP::Simple; use LWP::UserAgent; $ua = new LWP::UserAgent; $q = new CGI; $url = "http://10.50.1.1/pics/topbanner1.gif"; $req= HTTP::Request->new(GET => $url); $page = $ua->request($req); if ($page->is_success) { $pic=$page->content; print $q->header, $q->start_html('hello world'), $q->h1("<img src='$pic'>"), $q->end_html; } else { print $q->header, $q->start_html($page->error_as_HTML), $q->h1($error), $q->end_html; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Printing inline images
by fglock (Vicar) on Jul 03, 2003 at 01:00 UTC | |
by satanklawz (Beadle) on Jul 03, 2003 at 01:32 UTC | |
|
Re: Printing inline images
by cleverett (Friar) on Jul 03, 2003 at 05:12 UTC | |
by satanklawz (Beadle) on Jul 03, 2003 at 13:32 UTC | |
|
Re: Printing inline images
by fglock (Vicar) on Jul 03, 2003 at 01:36 UTC | |
by satanklawz (Beadle) on Jul 03, 2003 at 02:11 UTC | |
by cees (Curate) on Jul 03, 2003 at 05:11 UTC |