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
zura
Forum Newbie
Posts: 9 Joined: Mon Oct 17, 2011 1:04 am
Post
by zura » Sun Nov 06, 2011 2:10 am
Header(); does not works. Warning: Cannot modify header information - headers already sent by (output started at /home/sanikidz/domains/...).
Code: Select all
<?php
ob_start();
$nomeri = $_POST['operator'].$_POST['cellular'];
$messageText = $_POST['message'];
$e = "http://smsc.ru/sys/send.php?login=zura&psw=1111&phones=".$nomeri."&mes=".$messageText;
header("Location: $e");
if ($e == "true") echo "was sent!";
ob_end_flush();
?>
Thanks for help.
Christopher
Site Administrator
Posts: 13596 Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US
Post
by Christopher » Mon Nov 07, 2011 12:12 am
You probably have a space or return before the opening <?php. Why do you have the output buffering calls around that code? They are not needed.
(#10850)