Page 1 of 3 123 LastLast
Results 1 to 10 of 21
  1. #1
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default error: headers already sent

    hi guys i have a zen shop running - www.aquadeeziac.com

    must say awesome, i am just having a bit of hassle at the mo, if i add a new catergorie i get this message when my customers try and view it

    Warning: Cannot modify header information - headers already sent by (output started at /home/camnet/public_html/shop/includes/languages/english/index.php:117) in /home/camnet/public_html/shop/includes/functions/functions_general.php on line 44
    i dont know why or how to fix

    if you would like to try it is under my livestock header then live sand

    many thanks in advance for your help!!

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: hi

    If you do a search on the error message either in the tutorials/FAQs, Wiki or the forum ... you will discover a wealth of information about the typical php error that results from space(s) or blank line(s) before or after the opening php tag, <?php or after the closing php tag ?> ...

    If you were to edit the file listed in the error message and remove the space(s) or blank line(s) after the closing php tag ?> in the error message ... this would correct the problem ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: hi

    That's something wrong with your includes/functions/functions_general.php file at around about line 44. Can you post the code at this line and a 4-5 lines either side of it?
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  4. #4
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default Re: hi

    okay i am new to all of this, so please bear with me;)

  5. #5
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default Re: hi

    okay here goes

    while (strstr($url, '&amp;&amp;')) $url = str_replace('&amp;&amp;', '&amp;', $url);
    // header locates should not have the &amp; in the address it breaks things
    while (strstr($url, '&amp;')) $url = str_replace('&amp;', '&', $url);

    header('Location: ' . $url);

    zen_exit();
    }

    /**
    * Parse the data used in the html tags to ensure the tags will not break.
    * Basically just an extension to the php strstr function
    * @param string The string to be parsed
    * @param string The needle to find

  6. #6
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default Re: hi

    sorry took from line 40

  7. #7
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: hi

    Not a problem. I'm afraid I'm leading you astray. The code you posted from functions_general looks fine, but there shouldn't be 117 lines in your index.php suggesting that it has developed a problem.

    Two solutions: either upload a fresh copy, or if that doesn't work, goto the ?> at the end. Place you curser immediately after it, then press delete a few times to get rid of any extra hidden characters and save it.
    Last edited by Ajeh; 25 Jul 2007 at 05:46 PM. Reason: tidying typo
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  8. #8
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: error: headers already sent

    As Ajeh mentioned, here's an FAQ explaining how to respond to that error message:
    https://www.zen-cart.com/tutorials/index.php?article=87

    As kuroi mentioned, your file might be bad.
    Zen Cart files should not be double-spaced. Sometimes fantastico installations leave the files mucked-up.
    If yours is double-spaced, you should obtain a copy of the original by downloading the Zen Cart master zip file, and extracting a fresh copy of your file from it.
    .

    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.

  9. #9
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default Re: error: headers already sent

    guys thank you very much i deleted the function_general.php file and re uploaded

    sorry for my late response

  10. #10
    Join Date
    Jul 2007
    Location
    south africa
    Posts
    73
    Plugin Contributions
    0

    Default Re: error: headers already sent

    okay sorry guys, my problem is not fixed at all everytime i add a newproduct it gives me error messge for the heading i put it under??

 

 
Page 1 of 3 123 LastLast

Similar Threads

  1. Error creating Admin Notifier: headers already sent
    By jeffiec in forum Code Collaboration
    Replies: 5
    Last Post: 28 Jun 2016, 08:52 PM
  2. Error after adding product - headers already sent
    By comimpact in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 8 Feb 2008, 01:13 AM
  3. Installing shipping module causes headers already sent error
    By swguy in forum Built-in Shipping and Payment Modules
    Replies: 3
    Last Post: 22 Dec 2007, 06:19 PM
  4. Headers already sent error
    By e-hol.co.uk in forum General Questions
    Replies: 2
    Last Post: 9 Sep 2007, 04:40 PM
  5. Headers Already Sent Error !
    By ccn1 in forum General Questions
    Replies: 8
    Last Post: 5 Jun 2006, 03:07 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