Reply to Re: sending a post to another php script

Your name:

Reply:


Posted by Rob D on 04/03/07 15:18

You can do as various others have suggested but there is a built in
php way:

$vars = array("id" => $_REQUEST['id'],
"header" => $_REQUEST['header'],
"abstract" => $_REQUEST['abstract'],
"body" => $_REQUEST['body']
);
http_post($server, $port, $url, $vars);

It's perhaps self-explanatory, I'm getting four posted attribute/value
pairs from the request stream which I'm storing with the same names
(you could change them if you wanted) into an array called $vars. I
then call http_post passing the server, port and url of where I'm
connecting to with the posted array as the last parameter.

Rob

On Fri, 30 Mar 2007 13:21:33 +0800, Man-wai Chang
<toylet.toylet@gmail.com> wrote:

>
>I knew the GET way ('called.php?para1=aaa&para2=xxxx'),
>but how about the POST way?

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация