My footer has disappeared

Discussion in 'PHP' started by templates, Jan 8, 2015.

  1. #1
    All of a sudden, the footer.php does not show on my website, but I can clearly see the file on my server and can add links in the file, but nothing shows...any ideas?
     
    templates, Jan 8, 2015 IP
  2. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #2
    A link to the site would probably help. How is the footer.php included in other files? Are you getting any console-errors?
     
    PoPSiCLe, Jan 8, 2015 IP
  3. Anveto

    Anveto Well-Known Member

    Messages:
    697
    Likes Received:
    40
    Best Answers:
    19
    Trophy Points:
    195
    #3
    Could be one too many divs you closed/left open, something you did in the css, a fatal php error that you are not displaying, etc.

    A link to the site or some code would be helpful.
     
    Anveto, Jan 8, 2015 IP
  4. templates

    templates Notable Member

    Messages:
    4,772
    Likes Received:
    218
    Best Answers:
    0
    Trophy Points:
    205
    #4
    I appreciate your response.. http://4do.org/
    i have owned this site for several years and this happened suddenly..i am sure its simply fix, i just cant find it
     
    templates, Jan 8, 2015 IP
  5. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #5
    Wow. That code... it's so bad it should be taken behind the shed and shot. Repeatedly. Over and over. And then again.
    That being said - since we have no idea what the content of footer.php is, there's no way to know if it's there or not, but the site itself doesn't show any missing code, non-showing html or other errors. So I'm assuming there's an error in parsing, or similar. However - when you load up a link on the page, say the first one, "Advertising", it loads up http://4do.org/realtors-469.html - which is a html-file, not a php-file. You won't be able to load footer.php into that, unless you're doing some trickery behind the scenes.
     
    PoPSiCLe, Jan 9, 2015 IP
  6. ThePHPMaster

    ThePHPMaster Well-Known Member

    Messages:
    737
    Likes Received:
    52
    Best Answers:
    33
    Trophy Points:
    150
    #6
    There is something wrong going on with your "link/category calculation script". This happened last year (sometime after August 30th). To me it seems like a fatal error is occurring in your website that is stopping it from loading the rest of the content (as you can see from your source).

    Have you made any changes to hosting, configurations, etc.. Try enabling error reporting on your main index.php file and then you can actually see the error that is occurring:

    
    <?php
    error_reporting(-1);
    ini_set('display_errors', 'on');
    
    PHP:
     
    ThePHPMaster, Jan 9, 2015 IP
  7. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #7
    Are we looking at the same page? I can't for the life of me get up any errors (except if I turn adblock off, I get a "Favicon not found" 404-error - hardly a page-killer.
     
    PoPSiCLe, Jan 9, 2015 IP
  8. ThePHPMaster

    ThePHPMaster Well-Known Member

    Messages:
    737
    Likes Received:
    52
    Best Answers:
    33
    Trophy Points:
    150
    #8
    It is more like an educated guess. His current page source ends in:

    
    <HR SIZE=1 COLOR="#DDDDDD">
    
    Code (markup):
    I assumed that something is suppose to be there, which waybackmachine confirms:

    
    <HR SIZE=1 COLOR="#DDDDDD"><!-- insert link/category calculation script -->
    
    Code (markup):
    Usually this happened to me in the past when a fatal error occurs and error reporting is turned of, the page just stops outputting anything.
     
    ThePHPMaster, Jan 9, 2015 IP
  9. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #9
    Ah, true. I looked at the code, and it was missing so much proper formatting I didn't even think about it might missing something.
     
    PoPSiCLe, Jan 10, 2015 IP
  10. ezprint2008

    ezprint2008 Well-Known Member

    Messages:
    611
    Likes Received:
    15
    Best Answers:
    2
    Trophy Points:
    140
    Digital Goods:
    1
    #10
    you probably have a broken HTML code somewhere above it ? say </b
    a tag isn't closed somewhere so its not reading the include('footer.php') as a code of its own.
    thats usually the problem..check your code first.
     
    ezprint2008, Jan 12, 2015 IP