If you are not registered or logged in, you may still use these forums but with limited features. Show recent topics
  [Search] Search   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [FAQ]  FAQ 
[Register] Register / 
[Login] Login 
Warning: Cannot add header information  XML
Forum Index » Support Forum
Author Message
hela
Beginner
[Avatar]

Joined: 18/03/2002 08:27:10
Messages: 5
Location: Switzerland
Offline

Hi all,

My poll is working, but after having done a vote there is always the following error on top of the page.

Warning: Cannot add header information - headers already sent by (output started at /home/h/hela.li/public_html/index.php:2) in /home/h/hela.li/public_html/poll/poll_cookie.php on line 21

In my homepage the respective code looks like this:

<?php
/* Include this before your html code */
include_once "/home/h/hela.li/public_html/poll/poll_cookie.php";
?>


After having read similar problems here in the forum, I guess my problem has to do with the real path. My provider/hoster says the following:

Der Pfad setzt sich folgendermassen zusammen:

/home/i/ihrdomain.ch/public_html/

Das Zeichen nach /home/ (im Beispiel ein i) steht für das 1. Zeichen Ihres Domainnamens. Wenn Ihr Domain also 4webmaster.ch hiesse, dann wäre es eine 4.


Thanks for your hints

hela
[WWW] [ICQ]
spor
Student

Joined: 18/04/2003 05:02:37
Messages: 50
Offline

hi,
Make sure there are no spaces before the <?php
it has to be the first line of code.before your <html>

Go here for guestbook and poll help :: Spisas Guestbook
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

Yep, he's right PHP is very particular about syntax and white spaces. If there are any before it the script will not work. Its not a leanient as html is where you you can get away with odd mistake.

Auron
[Email] [WWW]
hela
Beginner
[Avatar]

Joined: 18/03/2002 08:27:10
Messages: 5
Location: Switzerland
Offline

Thanks guys!

That was it, now it works without error message

hela :lol:
[WWW] [ICQ]
 
Forum Index » Support Forum
Go to:   
Based on the open source JForum