Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

PERL and SSI

Posted on 2004-10-02
4
Medium Priority
?
313 Views
Last Modified: 2013-11-18
Ok, first of all, let me start off by saying that I am a front end designer and have very little programming knowledge.  So please answer me in dummy terms.

What I am using,
WinXP Pro, IIS, PERL installed

This page here works fine on its own, http://mp3nmore.com/cgi-bin/review/stars.pl

But when I try to add it to add that file via SSI into this page, http://mp3nmore.com/hi.shtml

It comes up as one big block of code as you can see, even though if I directly linked to that page it works fine.

What am I doing wrong????

This is the code on the hi.shtml page:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
</head>

<body>
<!--#include virtual="/cgi-bin/review/stars.pl" -->

</body>
</html>


0
Comment
Question by:krymp
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 13

Assisted Solution

by:StormyWaters
StormyWaters earned 100 total points
ID: 12209771
I _think_ you can do it like this:
<!--#exec cgi="/cgi-bin/review/stars.pl"-->

But I'm not sure, as I don't use CGI, thus this is untested.
0
 
LVL 16

Expert Comment

by:Sohel Rana
ID: 12210338
Hi:

Here is a step by step tutorial about how to call a SSI tag via cgi perl script  :


http://cpan.uwinnipeg.ca/htdocs/CGI-SSI/CGI/SSI.html

rsdn
0
 
LVL 5

Accepted Solution

by:
ITcrow earned 400 total points
ID: 12210756
Both the following are correct, if the server is apache.
<!--#include virtual="/cgi-bin/review/stars.pl" -->
or
<!--#exec cgi="/cgi-bin/review/stars.pl"-->

Now the reason, why your SSI is giving you wrong result is:
- Your CGI is included as text.
- Your CGI is not accepted as a CGI script.

IIS has it's own share of bugs, when it comes to SSI.

Try using:
<!--#exec cgi="/cgi-bin/review/stars.pl"-->
<!--#exec cgi="/cgi-bin/review/stars.cgi"-->
<!--#exec cmd="c:\perl\bin\perl c:/path/to/cgi-bin/review/stars.pl"-->

There are also known bug reports at microsoft site confirming IIS SSI problems.
0
 

Author Comment

by:krymp
ID: 12211130
Thanks everybody, this works: <!--#exec cgi="/cgi-bin/review/stars.pl"-->

0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Originally, this post was published on Monitis Blog, you can check it here . It goes without saying that technology has transformed society and the very nature of how we live, work, and communicate in ways that would’ve been incomprehensible 5 ye…
Ready to get certified? Check out some courses that help you prepare for third-party exams.
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question