Re: how can I get the post content in php

From: Date: Thu, 15 Nov 2001 08:13:33 +0000
Subject: Re: how can I get the post content in php
References: 1 2 3 4  Groups: php.general 
Request: Send a blank email to php-general+get-74682@lists.php.net to get a copy of this message
Hello Johan the program just can let me get the post string like my example I want post the xml file content to a php file, then I want get the post string that it's xml content. hehe, thanks for your help -- Yorgo Sun Project Manager Technology Dept. Tom.com Email:sunhe@bj.tom.com Mobile:13701243390 Phone:65283399-121 TomQ ID:yorgo http://www.ruisoft.com "Johan Holst Nielsen" <johan@1way2print.net> wrote in message news:20011115075915.34415.qmail@pb1.pair.com... > > $HTTP_SERVER_VARS['QUERY_STRING'] --> it just can read the content by GET > > method. > > > > I want POST content > > Ah okay. Try this: > > $post_query = ""; > $keys_arr = array_keys($HTTP_POST_VARS); > $keys_size = sizeof($key_arr); > for($i=0; $i<$keys_size; $i++) { > if($i == 0) { > $post_query .= $keys_arr[$i]."=".$HTTP_POST_VARS[$keys_arr[$i]]; > } > else { > $post_query .= "&".$keys_arr[$i]."=".$HTTP_POST_VARS[$keys_arr[$i]]; > } > } > > Regards, > Johan

« previous php.general (#74682) next »