[lug] Anonymous web host (OT)

John Starkey jstarkey at advancecreations.com
Mon Jun 30 00:04:53 MDT 2003

On Sun, 2003-06-29 at 18:51, Ben Luey wrote:
> I have a web page hosted on a server A that does support php, which I want
> to use. So I found another server (B) that does, but I don't what to
> change the url for my webpage to obscure.random.net/strangedir/me -- is
> there a way to have current web page just load the other web page
> transparently so surfers don't see that they the page is running off
> server B? I know I could do this with a large frame, but I'm hoping there
> is a better solution. Server A supports some perl, but with some security
> limitations on it or something like that.

Ben, check out file() (http://www.php.net/file - they have an example on
that page that will do what you want). You'd have to create the files on
Server B with the same names, unless you have write access to the

If you have write access to the http.conf, look into apache's ForceType.
Basically you can create a file called www and make that your
DocumentRoot, then with apache's <Location> directive do a ForceType on
that www file to make apache always parse it as php. Then:

$url = file( 'http://server-a.com'.$_SERVER['REQUEST_URI'], 'r' );
foreach( $url as $bit ) echo $bit;

This should echo the page for you.


John Starkey
Advance Creations

More information about the LUG mailing list