Forum Moderators: coopster
I'm using a cgi script to generate content in part of my site. I had been using the virtual() command, however when I moved to a new host I found that virtual() is not supported and I needed to use include(). PHP is being run as a CGI.
The only way I can find to include() the script is by using the full url. While this works well, it seems to double my bandwidth usage, as the php script calling the cgi is counted as bandwidth. My concern is that if the site grows any more it could put pressure on my bandwidth limit.
Any suggestions on alternate ways to include the output of the CGI script?
Many thanks,
Don
Thanks for the suggestions.. My first step was to contact them and they suggested using return() instead of virtual(), which definitely does not work. I've tried exec() but it does nothing.
Is it possible for a host to enable virtual() on a site-by-site basis? Actually I'll ask my host and get back with any info they can provide. I agree that include() is burning up bandwidth, essentially I'm using twice as much as I should be :)
Don
The only reason that it worked before was that the previous server has PHP installed as an
Apache module. The virtual() function is not a standard function, it's specific to servers
running the mod_php system. For greater functionality with other PHP functions and better
security with PHPSuExec, we decided to install PHP as a CGI module instead.
Thanks,
Don