CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
How do I make ssi work in cgi?

 



allanonline
Novice

Sep 2, 2002, 5:43 PM

Post #1 of 4 (330 views)
How do I make ssi work in cgi? Can't Post

I am using the following to display a banner on a .shtml page

<!--#include virtual="banner/banner.cgi?cat=Index" -->

and it works fine.

How do I get this to work in a .cgi page?

Thanks for any and all help.

Allan
Unsure


thebitch
User

Sep 2, 2002, 11:02 PM

Post #2 of 4 (329 views)
Re: [allanonline] How do I make ssi work in cgi? [In reply to] Can't Post

Why would you want to?

a ".cgi page" is usually a perl program.

Perl programs have the AMAZING
ability to invoke other programs, including
perl programs,
so just do that (invoke banner/banner.cgi from withing
a .cgi page )


allanonline
Novice

Sep 3, 2002, 4:10 AM

Post #3 of 4 (324 views)
Re: [thebitch] How do I make ssi work in cgi? [In reply to] Can't Post

I realize that SSI is a way of bringing the perl script

into an html document, what I'm having trouble with is

bringing this code back into cgi. I'm new to cgi and all

I have is the code from someone elses program. The only information provided

with the code was how to display the banners in a .shtml document, but nothing

on how to display it within a .cgi document.



I hope this clarifies my situation a little better.

Thanks

Allan
Unsure


davorg
Thaumaturge / Moderator

Sep 3, 2002, 7:03 AM

Post #4 of 4 (320 views)
Re: [allanonline] How do I make ssi work in cgi? [In reply to] Can't Post

CGI programs do not get processed by the SSI processor (because they've been processed by the CGI processor instead).

Therefore, if you want to include an SSI call in the output of CGI program, then you'll have to explicitly call the SSI program, capture its output and insert it into the output stream at the appropriate point.

--
Dave Cross, Perl Hacker, Trainer and Writer
http://www.dave.org.uk/
Get more help at Perl Monks

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives