Im pretty new to this stuff, but i am trying to take a CGI file and embed into a php file.
Basically i am running phpnuke 6.0 and added a module called CGi:IRC and wanted that to open in the module area, so i created a basic index.php (from other modules and copied the CGI file into) yea i know not the smart way, but hey always trying the easy thing first, then ask questions.
So if anyone can give me a hand that would be great
Thanks
Dave
OK Well i changed it up a bit
<?php
if (!eregi("modules.php", $PHP_SELF)) { die ("You can't access this file directly...");}
$module_name = basename(dirname(FILE));
include ('header.php');
OpenTable();
include("<!--#exec cgi=\"../www/modules/CGIIRC/irc.cgi\" -->");
CloseTable();
include ('footer.php');
?>
but now i get these errors when i load the page
Warning: main(): failed to open stream: No such file or directory in /home/echelon/www/modules/CGIIRC/index.php on line 6
Warning: main(): Failed opening '<!--#exec cgi="../www/modules/CGIIRC/irc.cgi" -->' for inclusion (include_path='.:/usr/local/share/pear:/usr/local/lib/php') in /home/echelon/www/modules/CGIIRC/index.php on line 6