I am using the last Dreamweaver CC. Everytime I load a web page to edit, the PHP includes show up as the tag only. It used show the content of the PHP include in the web page (see attached). If I highlight the tag and then cut and paste it back in, it shows up corectly, with the content of the include in the page.
Your screenshot doesn't tell us much.
Which local testing server are you using?
Is your local server launched and are all PHP and Apache processes running correctly?
Are dynamically related files discovered by DW? You should see includes among your dependant files accross the top of your screen. See screenshots.
Excuse me Nancy,
you know I do have a similar problem and nothing has changed since my last request.
If I use one of the newer DW editions than 2015 (16.0.0) I can't see the icons of my includes.
see my screenshot:
Would you please have a look at Kunstreiter Kaufbeuren where I use in line 139
<?php include("includes/InclMen.php"); ?> and in line 186 >>> <?php include("includes/InclAllgAng.php"); ?>
I can't see PHP code online.
Try split view with Live View turned on.
Go to View > Live View options > Use Testing Server for Document Source.
Do you want to the see the contents of your include file in design view?
In edit > preferences > invisible elements have you got this setting 'show contents of included file' checked?
I already have that box checked. It is not showing.
I am not running a testing server at all. This is purely local. One the last few updates caused my Dreamweaver CC to no longer show the contents of my included file, (this is the code I use to include it: <?php include("../../incl_header.html") ?>). If I remove it and then re-add it, it displays perfectly.
No testing server? Hmmmmmmm.
When I try to open a PHP file without a testing server, I'm prompted by DW to specify one. That is how DW has always worked for me since the early Macromedia days.
Ii am working in Design Mode. I have always had the the contents of the php file displayed alongside the rest of the page. In fact, if I remove the include and then re-add it, it displays perfectly. It just does not display when I first open the web page.
I agree with Nancy OShea... you should be getting asked to connect with a local testing server when using PHP includes. My sites will show text and local content of includes in Design view:
but will only show server-pathed media assets and PHP-processed content (from the server connection established in the include) once I switch to Live view:
Maybe double check your Servers section under your Site Definition to see if your Testing Server has the server model set to "PHP MySQL":
If the test server is the solution, then why does it work if I remove the include and then re-add it? Not only that, but I have several php includes on one page. None of them display when I first launch the page, but when I remove one, then re-add it, all of them suddenly are displaying correctly.
Obviously something is going on that you're not telling us. My 1st guess is that you have a sever running and don't know it. Maybe the server or drive that it resides on goes to sleep. When you delete and add the include code, it wakes up again. I imagine Ctrl+S to save file and F5 to refresh could have the same effect.
If that is the case, I have no idea what that could be. I have been doing hardware and software technical support for many years. I DO NOT have a server running.
Anybody else have any ideas?
Hello, because may problem is similar, I tried to interest an Adobe employee. You could find our correspondence at