View Full Version : How do i setup DW with WAMP on pc?

08-03-2011, 11:29 AM
When making websites in Dreamweaver, i would like view files containing Server Side Includes (SSI) and site root relatative links on my pc before uploading. This should be possible by installing WAMP and using the Apache-server.
But im having problems configuring both WAMP and DW to work. Right now, when previewing an .shtml file opened i DW no browser accepts the SSI.

The content of the DW-document saved as index.shtml in root of WAMP is:
<!--#include file="test.txt"-->
This is plain text

The content of SSI-document saved as test.txt and placed in root of WAMP is:
”SSI test on server?”

The visible result in the browser is only the line of text:
This is plain text

The path in the browser when previewed is:

Since ”SSI test on server?” isnt shown in browser SSI is not working.
But the really strange thing is that the file index.shtml is changing name in the path of browser to TMP1rmghpckjw.shtml file!
And that TMP1rmghpckjw.shtml is stored in WAMP root after preview..!

Obviously im missing something in the setup of DW and / or WAMP, so any help will be apprciated.

This is what ive done so far:

I have installed WampServer 2.1 -32bit on my Vista 32bit.

During installation:
I selected Firefox as primary browser
I wasnt offered the choice to pick a root-folder, so i assume root for WAMP is now file:///C:/wamp/www.
I have access to "www" from WAMP icon bottom-right of screen.

After the installation of WAMP:
I have typed http://localhost/ in Firefox and i get the WAMP-screen, WAMP is definitely working

In document Apache > httpd.conf (access from icon left-bottom) i have changed:
original line: Options Indexes FollowSymLinks
to new: Options Indexes FollowSymLinks Includes

original lines:#AddType text/html
#AddOutputFilter INCLUDES
to new
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml

New Site / Manage Sites:

I have created my testsite ”links” containing the SSI in WAMP root like this: C:\wamp\www\
Assigned my local root folder to be: C:\wamp\www\links\
Set links relative to Site Root
And set the http: as: http://localhost/links/ (http://localhost/links/)

In DW's section for Testing Server i have added this:

Server Model: PHP / MYSql
Access: Local/Network
Testing Server: C:\wamp\www\links\
URL Prefix: http://localhost/links/

In Edit > Preferences > Invisible Elements i have checked ”Server Side..”

In Live View i have checked ”Use Testing Server For Document Source”

One or more of these settings must be wrong. Ive been trying a lot of different combinations with no luck. Does anyone in the forum know how set things up? At the monment the goal is only to view SSI and Site Root links on my pc by using WAMP's Apache server, no PHP or database needed..

08-03-2011, 11:53 AM
I don't know if this will help as I'm just getting used to the new DW CS5 and CSS -- just upgraded. But, I do have my DW working on my WAMP server and on my Remote Server. Here's what I did and you can see if it works for you.

I have my test (WAMP) DW files set up under the C directory, WAMP folder and then in the www folder. Then I just called it whatever site name I wanted. C: > WAMP > www > "site_name"

The DW site Manager doesn't have any problem finding my index.html file in this folder when I use the "test server" dropdown in the file manager.

When I want to view my website in a browser. I have to add the site name after the local host as it can't find the page as index.html.

So, the localhost/index.html comes up with a blank or can't find page.
I change the index.html to read (like I used above as example) site_name and it pops up and works fine.

I also set the remote server to find my files in this same location. So in the remote server set-up, I told it to go to the same C: location and it's working from there.

I'm probably not doing this correctly, but it is working for me. I tried to save my site just under the top directory in C: before and it wouldn't find. Once I moved it into the WAMP server directory under wwww, it worked. That's where I have to put my Concrete5 CMS files when I use that instead of DW so it was kindof a clue that it needed to go there (or, at least, I think it does). Hope this helps. But, again, I'm pretty new to the new version of DW and CSS so may be way off in what I'm telling you, so please forgive me if I am. I'm just trying to help -- I found this site by accident and I've posted a problem I'm having. I've read through about everything so far and I'm finding this site to really fantastic and people see to be really helpful. :smile:

08-03-2011, 12:46 PM
My setup in dreamweaver that works fine is

Access: Local/network
Remote folder: c:\wamp\www\

I then use the syncronize button on Dreamweaver to put all the files to that location. I then hit F12 on the page that I am editing and it opens in the default browser.

08-04-2011, 01:57 AM
Hi and thx for replies.
I cant get it to work. This WAMP / Apache-configuration is hairpulling!
Ive tried all possible combinations in both DW and WAMP, but i still cant preview content of Server Side Includes (SSI) in a browser.
And the index-file is still being mysteriously renamed in browser-path when previewed.

Have any of you used Server Side Includes (SSI) saved as .txt document and can you actually see the SSI-content when previewed in a browser from DW?
Thats what installing Apache should be able to do on a local machine. But how..

08-04-2011, 05:08 AM
on wampserver they recomend
Options Indexes FollowSymLinks

change to:
Options +Includes Indexes FollowSymLinks
note the +

08-04-2011, 09:26 PM
The Options settings confuses me:
In the httpd.conf there are two different lines containing Options.

First one is in the directory. Looks like this in the original httpd.conf:
# First, we configure the "default" to be a very restrictive set of
# features.
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all

Second one is placed futherdown in the documnent. Looks like this in the original httpd.conf:
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs/2.2/mod/core.html#options
# for more information.
Options Indexes FollowSymLinks

Do i make the changes in the second one?

08-05-2011, 02:15 AM
i would say the second one. just keep a back up so you can CYA inacse of error

08-05-2011, 02:32 PM
Found the below on the web. Sounds like it's following what this site's experts are saying. I don't understand any of it as I don't use SSI, but give the below a try and maybe it will help. I know how frustrating it can be when you spend hours and hours trying to get this stuff to work. Hope it works for you.

How to add SSI (Serverside include support in WAMP)?
Open http.conf file from < your drive):\wamp\bin\apache\Apache2.2.11\conf (e.g. C:\wamp\bin\apache\Apache2.2.11\conf)
Then add the following code:
AddType text/html .shtml
Options +Includes
AddOutputFilter INCLUDES .shtml
The above code should be above "<Directory />" in httpd.conf file
Then find "Options Indexes FollowSymLinks" and replace it with:
Options +Indexes +FollowSymLinks +Includes
Restart wamp and enjoy.

08-06-2011, 09:50 AM
Thx for replies
WAMP is up and running fine; i can preview both SSI and root relatave links.

Regarding configuration in Apache's htppd.config document, ive tested what works and what doesnt. Following two adjustments will be the simplest possible and work on WampServer 2:

1. Add Includes in this line:

# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs/2.2/mod/core.html#options
# for more information.
Options Indexes FollowSymLinks Includes

2. Remove the sign # in these two lines:

#AddType text/html .shtml
#AddOutputFilter INCLUDES .shtml

Save httpd.config, Restart All Services in WAMP and now SSI inclusions in .shtml documents can be previewed locally. Provided that site-folders and DW is set up correctly!

12-10-2013, 07:35 AM
I had this problem too. I did what you said. now it's working.
my question is: why this problem is happened
before today my testing server was setting up perfectly but today its didn't work suddenly although I didn't change anything
thanks for your useful post