Skip to main content
Participant
August 25, 2006
Question

Why does CSS layout vanish when php include added?

  • August 25, 2006
  • 1 reply
  • 503 views
I am developing a mid sized web site using CSS layout, which has a persistant nav menu throughout. Seeing that theere is a pretty good chance this will be amended, I have decided to treat this element as a php include file.

When I add the php include into a main page, the CSS layout goes nuts. Within the design view of Dreamweaver, everything below the include point disappears, but works fine through a browser from the testing server.

I guess this is not a fault, but as a designer, it is difficult, and disconcerting to work with pages when half the page is missing.

Am I missing something.??


<div id="nav">

<?php include("menu.php"); ?>

</div>
This topic has been closed for replies.

1 reply

Inspiring
August 28, 2006
Make sure that your menu.php file does not have <html>, <head>, or
<body> tags.

HTH,
Randy


> When I add the php include into a main page, the CSS layout goes nuts. Within
> the design view of Dreamweaver, everything below the include point disappears,
> but works fine through a browser from the testing server.
>
> <?php include("menu.php"); ?>
*Anton*Author
Participant
August 29, 2006
Randy,

that's done it. Many thanks.

A