homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

ssi include for web stat tracking on the php pages
how do we get a ssi include to work on php?

 4:31 am on Jan 8, 2002 (gmt 0)

here is my ssi

<!--#include virtual="/_tx/traxis-counter.cgi?site=atwstat"-->

is is not being parsed / read by the tracking program on *.php pages ...

any thoughts?

This Does Work On html with

Options Includes +ExecCGI

AddType text/x-server-parsed-html .html .htm



 5:19 pm on Jan 8, 2002 (gmt 0)

I don't think you can get PHP and SSI to coexist on the same page, but PHP has the virtual() function which does more or less the same job eg


This apparently only works if PHP is installed as an Apache module - I think it usually is.


 6:14 pm on Jan 8, 2002 (gmt 0)

any other ideas???
this is the warnong message i get

<b>Warning</b>: Unable to include '/_tx/traxis-counter.cgi?site=atwstat' - request execution failed in <b>/home/sites/site30/web/content/index.php</b> on line <b>3</b><br>


 6:25 pm on Jan 8, 2002 (gmt 0)

$fpt = fopen("http://full/web/path/_tx/traxis-counter.cgi?site=atwstat");

I think the problem in the previous example lies in the query string. Im not sure if this will work either. Be sure to change the path.


 6:27 pm on Jan 8, 2002 (gmt 0)

<!--#include virtual="/_tx/traxis-counter.cgi?site=atwstat"-->

<!--#include virtual="/_tx/traxis-counter.cgi?site=atwstat" -->

SSI's need to have that extra blank space after the final quote. Could that be it?


 6:28 pm on Jan 8, 2002 (gmt 0)

Hmm, looks like it will work if the path is right. Try it without the leading / in "/_tx/", or if that doesn't work try the full server path/home/sites/site30/web/content/_tx/traxis-counter.cgi?site=atwstat


 7:49 pm on Jan 8, 2002 (gmt 0)

... nope..

here is my last try...

any more ideas??? thanks

$fpt = fopen("home/sites/site30/web/_tx/traxis-counter.cgi?site=atwstat");

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved