InMotion Hosting Support Center

Dreamweaver can't preview PHP files

Category: Dreamweaver

2013-08-13 1:02 pm EST

Hits: 7,467
Within dreamweaver, there is a button "Live" to be able to see the website live on your Computer as you adjust the code.

For most page I have no problem, however it does not like PHP pages. I get the following error:

"Dynamically-related files could not be resolved because the site definition is not correct for this server"

Any thoughts?

You must login before you can ask a follow up question.

You must login before you can submit an answer.



9,968 Points
2013-08-13 1:30 pm EST
Hello hunterharmony, and thanks for your question!

When you're using the "Live" button within DreamWeaver to preview your website, this is essentially the same as opening up your web-browser, and then navigating to the HTML files located locally on your hard drive.

This works perfectly fine, because your web-browser is capable of rendering out HTML and CSS for styling the pages, so you see just what you'd see if you published these pages to your website.

However PHP is a dynamic server-side scripting language, meaning that first the code contained within the PHP script must be run on the server and processed, and then the resulting HTML code is displayed to your web-browser.

If you'd like to use this preview functionality of DreamWeaver with your PHP scripts your only option would be to install a web-server on your own local machine, so that it can process the server-side PHP code for you. Adobe actually has a really in-depth write up on setting up a PHP development environment for DreamWeaver that goes over installing a PHP-enabled web-server to your local computer, and defining a PHP site in DreamWeaver.

Of course your other alternative would be to simply upload your PHP scripts to your account with us, and then viewing them over the web from your website. Depending on how much updating of your scripts you intend to do, this could become very cumbersome, and is why a lot of PHP developers do go ahead and setup a local development environment to test on.

If you had any other questions at all, please let us know!

- Jacob

You must login before you can post a comment about this answer.

Like this Question?

Related Articles

Support Center Login

Our Login page has moved, Click the button below to be taken to the login page.

Need more Help?


Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail:
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!