Is there a reason the back-end PHP code could affect the layout of a page? This only happens in IE. In Firefox and Chrome, everything looks fine.
Thing is, we have this HTML code, then a back-end code for the functions on that page is inserted by <?php include "[name of file]";?>. The php file we included has no styling in it whatsoever but it mysteriously makes the whole page go to the left edge (instead of centered). If we remove that file from the page, it renders normally.
We have learned that if we comment out a certain part of the code on that file (view below), the layout gets fixed:
//function position_list() {
global $db, $core, $global;
ob_start('ob_gzhandler');
include ROOT.'templates/listing.php';
ob_flush();
//}
I’m just wondering if anybody has encountered a similar problem? What could be wrong?
Compare the source in IE with and without the include line. Is it what you expect? Are there any PHP warnings?
Quite odd to see you comment out the
function {}part without commenting out the body of the function. You’re effectively now callingposition_list();whatever. Which of the lines is it that is causing the rendering to change?If this is all before the doctyle and
<html>tag then it could be that the output is triggering the browser to render in quirks mode, rather than standard compliance mode.