Tag: gap
php include causing unwanted gap in web page
by Mark on Apr.18, 2009, under php
So, I was working on a new site and wanted to have the left menu as a standard php include:
<?php include("solutionsMenu.php"); ?>
But, when I loaded the page there was a big gap right above where the include was being rendered. It took me an hour to find out that I had accidentally saved the solutionsMenu.php with a ‘bite order mark’ which was adding a character at the very beginning of the file!
In your text editor you may have the option to set the encoding for the file. Make sure you are saving as UTF-8 not ‘UTF-8 with BOM’. Save the file without a BOM and the problem will disappear
Looking for something?
Use the form below to search the site:
Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!
















