1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Virtual Server

Discussion in 'Web Design & Development' started by nkchri2, Jan 14, 2011.

Thread Status:
Not open for further replies.
  1. nkchri2

    nkchri2 Thread Starter

    Jan 14, 2011
    I'm not sure if this is a Dreamweaver server settings problem, or an Apache problem, but I'm looking for some help to get a virtual server going.

    I'm just getting into php and have set up a local server on my computer. I installed everything with the current package of EasyPHP. I have installed everything fine, everything is set up, and I can see information when running <?php phpinfo(); ?>. I'm going through the book Adobe Dreamweaver CS5 with PHP if anyone happens to know the book. I'm using Windows XP. I'm trying to set up a virutal host for the first website. I believe I've followed everything in the book, but when I try and run the "site check" from lesson two which checks to see if the server is working I just get

    Object not found!

    The requested URL was not found on this server. If you entered the URL manually please check your spelling and try again.

    If you think this is a server error, please contact the webmaster.

    Error 404

    01/13/11 21:36:17
    Apache/2.2.17 (Win32) PHP/5.3.5

    I'm sorry for being lengthy, but I'm going to try and provide as much information as possible.

    The programs are installed to C:\Web Server\EasyPHP-
    C:\Web Server\EasyPHP-\www is the root and in the root I have the subfolder rampantreviews

    First off, I edited c:\windows\system32\drivers\etc\hosts file, which now look like this: localhost rampantreviews

    (there is no ::1 localhost)

    I opened up the apache httpd.conf file, I added near the bottom after the other includes:

    Include conf/extra/httpd-vhosts.conf

    I opened up the httpd-vhosts.conf file, I removed the # from NameVirtualHost *:8080 to activate that directive, and at the bottom of the file I added:

    <VirtualHost *:8080>
    DocumentRoot "C:/Web Server/EasyPHP-"
    ServerName localhost

    <VirtualHost *:8080>
    DocumentRoot "C:/Web Server/EasyPHP-"
    ServerName rampantreviews

    I noticed when setting up the programs, accessing my localhost only works through http://localhost:8888, but in apache its 8080 throughout the file? This doesn't affect it does it? I can also access http://rampantreviews:8888/test.php and it correctly displays info from <?php phpinfo(); ?>. So I'm really confused lol

    In dreamweaver I have the site setup. Local site folder is:
    C:\Web Server\EasyPHP-\www\rampantreviews\

    I set it like this as the book suggested since it would just be copying local files into the server folder when doing live view so you would just end up with two copies of everything, so its in the root folder.

    Testing Server is set up in the options, connect using local/network, server folder is:
    C:\Web Server\EasyPHP-\www\rampantreviews\

    web URL:

    Advanced, server model is PHP MySQL

    Testing is checked, remote is not.

    When I open up the lesson 2 file, dreamweaver says this page my have dynamically related files that can only be discovered by server... so I hit discover, and it says can't be resolved because site definition is not correct for the server.

    I know its alot of information >.< I have went back over the steps like 4 times and can't get it going or see anything wrong, I'm sure I'm just overlooking something. Any help to get it going would be greatly appreciated.

    Also, I did copy the lesson files into the rampantreviews folder. I have also restarted the server several times to pick up conf files changes.
  2. ehymel


    Aug 12, 2007
    Check your apache server log files... they are likely to be more informative than the on-screen errors that the browser shows you.
  3. nkchri2

    nkchri2 Thread Starter

    Jan 14, 2011
    OK, I checked the log files, and noticed whenever I tried to use live view on that file it says:

    [Thu Jan 13 21:45:55 2011] [error] [client] File does not exist: C:/Web Server/EasyPHP-

    So I tried removing the rampantreviews folder, I moved all the lesson files and folders back into the mian root folder (www). Reset the site definition in dreamweaver, loaded up the page, hit live view and it works. Normally this would be great... except I was pretty sure the actual installation and setup was fine... its the setup of virtual hosts that isn't.

    It said file didn't exist under www/lesson02... well it didn't, it was supposed to be a virtual host looking in www/rampantreviews/lesson02

    Also in Dreamweaver, even when everything is actually working and the page displayed correctly after being moved, Dreamweaver doesn't say dynamically related files couldn't be resolved because the site definition is not correct for the server anymore.

    The lesson file is a simple time app:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Testing server test</title>
    <link href="../styles/examples.css" rel="stylesheet" type="text/css" />

    <h1>The Moment of Truth</h1>
    <p>Click the Live View button. If the current time is displayed below, your testing server is working.</p>
    echo '<p>Congratulations. The time is now ' . date('g:i a') . '</p>';

    So this gets back to the main problem... and the main question lol

    How do I make a working virtual host? >.<
  4. ehymel


    Aug 12, 2007
    A few things to check:

    In your httpd.conf file, make sure you have a line like:
    NameVirtualHost *:8080

    NameVirtualHost *:8888

    Next, it's not clear why you are specifying port 8080 in your config files, but you can only access on port 8888. I suspect it has to do with the NameVirtualHost directive above.

    Do you have any other vhosts files? Make sure to check your conf.d directory, since the .conf files in that directory are included by default.
  5. Ainsley


    Jan 17, 2011
    Are you sure Apache is running MySQL - if so, do you have a version installed that is recommended to be used with the VirtualHost?
  6. ehymel


    Aug 12, 2007
    MySQL has absolutely nothing to do with this problem.

    I'm also not sure what you mean by a "version installed that is recommended to be used with the VirtualHost" ???
  7. sepala


    May 20, 2010
    What about using XAMPP ?
  8. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/974629

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice