> As for redirecting, you cannot force a client to send a POST request to another > URL (thankfully). So, you either need to send the POST request yourself (and > send the output to the client), or you need to think of another solution (such > as using URL variables for everything).
OK, that sounds good. So I have to change my approach a bit. Now I tried .... #!/usr/local/bin/php <?php $uri = $_ENV["REQUEST_URI"] ; $script = $_ENV["SCRIPT_NAME"] ; $para = substr(stristr($uri, ".cgi"),4) ; $rhost = "http://".$_SERVER['HTTP_HOST']."/cgi-bin/interchange_foundation.cgi".$para ; $xoops_interchange = "http://".$_SERVER['HTTP_HOST']."/xoops/modules/interchange" ; $fp1 = fopen($rhost,"r"); // !!!!!!! here I have to pass all the parameters !!!!!! $fp2 = fopen("/home/myuser/public_html/xoops_foundation_template.html","w"); while(!feof($fp1)) { $line = fgets($fp1, 4096); $line = str_replace("interchange_foundation.cgi", "xoops_interchange_foundation.cgi", $line); fputs($fp2,$line,strlen($line)); } fclose($fp1); fclose($fp2); echo "Location: ".$xoops_interchange."\n\n" ; ?> The whole thing is (should be) a wrapper for the interchage shop system. I would like to have that thing covered by a XOOPS modul. For that I wrote the script shown above. 1.) It should take all parameters passed to it like the original interchange cgi link does. 2.) Open the original interchange URL with all of them. 3.) Get the result page. 4.) Replace all interchange links to point back to this wrapper. 5.) Store the result page to be interpreted further by my XOOPS interchange modul (actually it simply adds some XOOPS tags and shows it) . 6.) And after all that just redircet to my XOOPS interchange modul main page. Actually that works really fine already for links and stuff. When it comes to a form, it fails - guess why ? īcaus of the missing POST parameters (obviously). How could I 'query' a URL with POST and GET Parameters with a PHP Script ??? fopen does not have that option, right ? With perl there is a CPAN modul that could act as a HTTPclient to handle such HTTP issues properly. Well, I am no perl guy (at least not now) and would like to have solved that issue with php ;). If it could not be (what I realy doubt) I will have to dive into perl. Again, any guess will be deeply appreachiated ... Stephan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php