RE: inserting variable image into a page

by anottingham(at)topazti.com (Amy Nottingham)

 Date:  Wed, 7 Mar 2001 15:49:02 -0600
 To:  "Nate Harel" <nharel(at)consultant.com>,
<hwg-techniques(at)hwg.org>
 In-Reply-To:  rcn
  todo: View Thread, Original
Hi Nate,

I am pretty new to this myself, but I would guess that if you want to use
Perl, you would write a CGI program that resides on your server, and you
would send it values through a form, which would get processed by your Perl
program on the server, and then the program would take the results and
output it to a new page which it would send the client.  I think you need
perl modules installed on your server in order to execute a perl program.  I
don't actually know how to write your own CGI, but the process I described
above is how most CGIs I have seen/used work.

I am wondering if for something like calling one of two images you would be
better off using javascript.  Depending on what you are using the images
for, you could do something like this pseudo-code:

if condition1 {go get image1}
else if condition2 {go get image2}

and maybe save yourself a lot of headache. (Or maybe not...)

Hope this is helpful.

Amy


-----Original Message-----
From: owner-hwg-techniques(at)hwg.org
[mailto:owner-hwg-techniques(at)hwg.org]On Behalf Of Nate Harel
Sent: Wednesday, March 07, 2001 1:01 PM
To: hwg-techniques(at)hwg.org
Subject: inserting variable image into a page


Hi all,

I want to build a page that calls one of two images to be placed on the
page. I considered writing a small Perl program that will be called when
the page is loaded, which will determine which image to load into the page.

Being relatively new to Perl I do not know exactly how to do that.

The question I have is how to include the portion of the perl program that
inserts an image into the existing page itself. All the documentation I
have seen refers to generating a new page with perl, but nothing so far has
shown me how to insert the image directly into the existing page.

Your help would be appreciated.

Thank you
Nate


		---------------------------------------------------
			 Nate Harel
		 Workright Technical Services
		        66 Carol Road
		  Needham, MA  02492-1108
		    Tel: 1-781-559-8176
		 Toll Free: 1-877-567-8936
		   FAX: 1-877-567-8936
		 Email: nharel(at)consultant.com
			www.wrkts.com
		----------------------------------------------------

HWG hwg-techniques mailing list archives, maintained by Webmasters @ IWA