Page 1 of 1

php header

Posted: Sat Nov 05, 2011 2:04 pm
by zura
Hi...
How can i send $e on this url: http://smsc.ru/sys/send.php
Header(); does not works. (Cannot modify header information - headers already sent by (output started at /home/...))

Code: Select all

<?php
ob_start();
$nomeri = $_POST['operator'].$_POST['cellular'];
$messageText = $_POST['message'];
$e = "?login=zzz&psw=zzz&phones=".$nomeri."&mes=".$messageText;
ob_end_flush();
?>
Thanks for help.

Re: php header

Posted: Sat Nov 05, 2011 3:19 pm
by Benjamin
:arrow: Moved to PHP - Code

Re: php header

Posted: Sat Nov 05, 2011 3:33 pm
by Celauran

Re: php header

Posted: Sat Nov 05, 2011 3:54 pm
by flying_circus
zura wrote:Hi...
How can i send $e on this url: http://smsc.ru/sys/send.php
Header(); does not works. (Cannot modify header information - headers already sent by (output started at /home/...))

Code: Select all

<?php
ob_start();
$nomeri = $_POST['operator'].$_POST['cellular'];
$messageText = $_POST['message'];
$e = "?login=zzz&psw=zzz&phones=".$nomeri."&mes=".$messageText;
ob_end_flush();
?>
Thanks for help.

What exactly are you trying to do? It looks like you are trying to append a querystring onto a uri. Are you trying to forge a post request to another site?

You can use cURL, you can use a standard HTML form, or you can craft a request using something like telnet. I think even firebug will let you go in an edit html elements inline.