Jump to content
The Uniform Server Community
Sign in to follow this  
envy

Links problem

Recommended Posts

Hi. i have a problem with links of my website since i've made changes to virtual host on apache conf file.

i've managed to make the www.mydomain.ro work but not all the links return this message :

 

Not Found

 

The requested URL /pages/Abonament.html was not found on this server.

Apache/2.0.59 (Win32) DAV/2 PHP/5.2.3 Server at www.mydomain.ro Port 80

 

httpd.conf -->

#MYDOMAIN

<VirtualHost *>

ServerName mydomain.ro

DocumentRoot /www/myfolder

</VirtualHost>

 

my website is in the myfolder folder.

 

Any way to solve this problem ?

Share this post


Link to post
Share on other sites

Your Vhost looks OK if I type this into a browser:

 

http://mydomain.ro

 

I will see your index page (served from folder www/myfolder)

 

However if I type this into my browser:

http://www.mydomain.ro

 

There is no matching Vhost (ServerName) for www.mydomain.ro

Hence it cannot be found and Apache will server pages from the first site listed in the Vhost section. However that is not consistent with the error message!

 

Take a look at this page http://center.uniformserver.com/u35_mod_ss...nfig_httpd.html

At the bottom of this page you are interested in the new column it gives the structure how Vhost are layed out the :80 are not required for your implementation.

 

You can have more that one Vhost pointing to the same root folder for example:

 

ServerName mydomain.ro

DocumentRoot /www/myfolder

 

ServerName www.mydomain.ro

DocumentRoot /www/myfolder

 

Not sure if that helps

 

All the best

Ric

:lol:

Share this post


Link to post
Share on other sites

Thanks for your answer Ric. I've tried your solution but it doesn't work. maybe it's the cms script. it uses a mysql database and all the links and pages are saved to that database. when i'm working with localhost it works but when i change to mydomain.ro only the main paige works and the links to the pages show the error message i've posted earlier.

Share this post


Link to post
Share on other sites

I think what may be required is an entry in your hosts file,

 

Open the file hosts located in folder:

 

C:\WINDOWS\system32\drivers\etc

 

Add a line similar to this

 

127.0.0.1 www.mydomain.ro

 

All the best

Ric :lol:

Share this post


Link to post
Share on other sites

Thanks again Rick. already tried it but still the same problem. still trying but i think i'm running out of ideas.

:)

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...