Click to See Complete Forum and Search --> : error in my POLL


_LOBO_
06-05-2003, 03:18 AM
Hi all again and TNX for any help.

I try to install a poll for my web page and I find this one:
Advanced Poll 2.0.2
http://proxy2.de/scripts.php

Is a really good poll with easy installation, the poll works but sometime I get this error:

Warning: Cannot modify header information - headers already sent by (output started at /u/web/sfane1/test/news/en.php:2) in /u/web/sfane1/poll/poll_cookie.php on line 21


This error it appears at the top of the web page.

In the head of my web page I have this:

<?php
// Important! You have to include it before your html code
include_once "/u/web/sfane1/poll/poll_cookie.php";
?>
<html>
<head>

I put this as the setup of the poll explain


and this is the poll code in the web page:

<?php
include_once "/u/web/sfane1/poll/booth.php";
echo $php_poll->poll_process(4);
?>

pyro
06-05-2003, 10:36 AM
From what you posted, here's what I can tell you:

That kind of warning means that PHP is trying to modify the header information (cookies, HTTP, etc) after contents has been sent to the page (including <html>,<head>,etc) Basically, you just need to make sure that the PHP script does not try to modefy the headers after contents has been sent to the webpage.