.htaccess, mod_rewrite & index.php |
[eluser]bparker[/eluser]
aaaah, i forgot to check that!!! one problem i neglected to mention is that www.mydomain.com/ now gives me the directory listing of /var/www/... ok, so i get:- www.mydomain.com/search file does not exist '/var/www/search' script '/var/www/index.php' not found or unable to stat it seems it's now looking for the index.php, but not finding it since it still thinks we're lokoing in /var/www/ any thoughts on this? maybe my sites in incorrectly configured... how do i ensure nothing ever sees /var/www/ but always goes to /webroot/search/ by default.... this is essentially what i get for all requests
[eluser]n0xie[/eluser]
It has your DocumentRoot set to /var/www (this is probably set by /etc/apache2/sites-available/default) so basically it's looking inside your /var/www because that's what the 'default' config says it should do. What you need to do is add a virtual host, so apache knows how to handle requests coming from 'somedomain.tld'. It doesn't know what to do with the requests so it sends you to the 'default' website, which in this case is /var/www. If you add a virtual host, like mine, where you specify what the Document Root should be for your site, it will probably all 'automagically' work. You should be able to get things working with this how-to. It will be a bit of trial and error but once you 'get' it, apache is actually quite easy to manage. Also take a look here
[eluser]bparker[/eluser]
---SOLVED--- I am absolutely astounded by this forum, I can't believe that, without even asking me anything too technical you have managed to solve this problem for me!!! N0xie: You're last comment did indeed work "automagically". as soon as i altered the sites-available config file to use <VirtualHost www.mydomain.com:80> everything did indeed "just work!!!" eoinmcg: It was your comments about AllowOverride must not be None that lead me in the correct direction! Thanks again for all your help, absolutely perfect work!!! |
Welcome Guest, Not a member yet? Register Sign In |