Grabbing the QUERY_STRING of a remote server

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
chriswheat
Forum Newbie
Posts: 8
Joined: Fri Oct 03, 2003 12:11 pm

Grabbing the QUERY_STRING of a remote server

Post by chriswheat »

Hello,

does any one know how to grab the quiry string of a remote server?

I tried the following however it grabs the query string of my server.

Code: Select all

<?php

        $url = "http://www.ibanksystems.com/passage/";

        $filepointer = fopen($url,"r");
	
if($filepointer)&#123;

$query=$_SERVER&#1111;'QUERY_STRING']; 
echo $query;


            &#125;

            fclose($filepointer);

        

    ?>
Thanks in advance.

Chris
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

what do you expect that query-string to be?
then the querystring certainly is empty.
If you want to know wether you can fetch the real location of the document that is served the answer is "no"
and neither is it possible the fetch the variables of another (remote) script. You wouldn't want all the nerds there are in the universe to be able to fetch your script's variables either ;-)
Post Reply