Help needed will pay ASAP

Discussion in 'PHP' started by paul7777, Mar 28, 2007.

  1. #1
    Hi All,

    My site as just gone down today and i am getting this error:

    Unable to add cookies, header already sent.
    File: /home/talkhome/public_html/index.php
    Line: 1


    Looking for someone to fix it ASAP and i will pay.

    Please just check out the url and you will see the error: www.talkhomebusiness.com
     
    paul7777, Mar 28, 2007 IP
  2. Diether

    Diether Peon

    Messages:
    278
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Open your index.php file and look for any html tags before getting the cookie information
     
    Diether, Mar 28, 2007 IP
  3. srobona

    srobona Active Member

    Messages:
    577
    Likes Received:
    57
    Best Answers:
    0
    Trophy Points:
    88
    #3

    Besides, look for any print command (print/echo) before the cookie info, or any white space.
     
    srobona, Mar 28, 2007 IP
  4. linkstraffic

    linkstraffic Well-Known Member

    Messages:
    388
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    133
    #4
    send me your file, I ll look into it and fix it (must be some white space or something like that as mentioned by srobona)
     
    linkstraffic, Mar 28, 2007 IP
  5. streety

    streety Peon

    Messages:
    321
    Likes Received:
    15
    Best Answers:
    0
    Trophy Points:
    0
    #5
    You could also give headers_sent a try. Never had cause to use it myself but it looks like it should be able to help you.
     
    streety, Mar 28, 2007 IP
  6. JEET

    JEET Notable Member

    Messages:
    3,832
    Likes Received:
    502
    Best Answers:
    19
    Trophy Points:
    265
    #6
    You are trying to set a cookie after an "include" or "require" command.
    These are being used to include your template... Either put the "setcookie" command above the include, or put the include command after it.
    Reason is the same as mentioned in posts above, you cannot send anything to browser before you send a cookie (if sending a cookie).
    Bye :)
     
    JEET, Mar 28, 2007 IP