Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2008
    Location
    WA
    Posts
    555
    Plugin Contributions
    0

    Default How did she know "headers already sent" was junk in file?

    I was getting a lot of warnings in my log files:
    "Php warning: Cannot modify header information - headers already sent <file one> <file two>


    and <file one> was always the same file, <file two> varied. I was going to edit file one because that is what I was working on yesterday but I wasn't sure what to look for.

    I searched on "headers already sent" and found this response by Ajeh:
    Based on the error message, check the file:
    <file one>

    and remove the space(s) blank and/or line(s) at the start of the file before the opening php bracket <?php and see if this corrects the problem ...

    As a precaution, check at the bottom of the file and if there is a closing php bracket ?> remove that as well .
    It worked. I had leaned on my keyboard or something before I closed the file yesterday and there were some random characters at the top.

    My question is twofold:
    1. How did she know (just experience or was it a specific behavior of the header files?
    2. Why is their no closing php bracket?

    My guess is that it is something about the way the developers structured zencart?

    Thank you Ajeh for the solution and anyone for the explanation. Also, I started a new thread because this was buried in a template forum.


    PS: I didn't post the file name because mine was different than the original post so I thought it didn't matter. But it case it does, I was editing meta_tags.php in includes/modules/mytemplate/
    Last edited by lruskauff; 2 Jul 2015 at 05:59 PM.

  2. #2
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: How did she know "headers already sent" was junk in file?

    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Sep 2008
    Location
    WA
    Posts
    555
    Plugin Contributions
    0

    Default Re: How did she know "headers already sent" was junk in file?

    Thank you, I should have kept searching. Linda

 

 

Similar Threads

  1. v154 Blank screen after curesec-com file insert ("headers already sent")
    By RixStix in forum General Questions
    Replies: 4
    Last Post: 13 Sep 2015, 09:58 PM
  2. Urgent Help Needed - "headers already sent"
    By CnTGifts in forum General Questions
    Replies: 2
    Last Post: 17 Mar 2008, 07:44 AM
  3. "headers already sent" error in 1.37 upon fresh installation
    By robax in forum Installing on a Windows Server
    Replies: 4
    Last Post: 19 Feb 2007, 02:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg