Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Is there a way use cgi within ZC

Is there a way use cgi within ZC

Locked

Views: 952

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
23 Aug 2006, 4:27 AM
#1
gwmbox avatar

gwmbox

New Zenner

Join Date:
Feb 2005
Posts:
38
Plugin Contributions:
0

Is there a way use cgi within ZC

Hi guys

I have a FAQ system I like (smartfaq) that uses Perl, is there a way I can wrap the ZC look and feel around a cgi script. Thh script normaly uses a header and footer html file for that but how can I get it to work with ZC? The script is also simply used by calling the script itself.

Cheers

23 Aug 2006, 4:49 AM
#2
gwmbox avatar

gwmbox

New Zenner

Join Date:
Feb 2005
Posts:
38
Plugin Contributions:
0

Re: Is there a way use cgi within ZC

I should try a little harder before I post - sorry :)

Anyway in case anyone else is looking for a similar solution for their perl script

In the define page for that page you create for the script add the code

<?php
$QSTRING = $_SERVER['QUERY_STRING']; 
while (list ($header, $value) = each ($HTTP_GET_VARS)) 
{ 
$QSTRING = $QSTRING.'&'.$header.'='.$value; 
}
virtual("/cgi-bin/scriptname.cgi".'?'.$QSTRING);
?>

Cheers