Forum Moderators: phranque
I am moving sites from server1 to server2 - when all sites are moved, i will point domain names to server2.
Untill then i test the sites using
#*$!.xxx.xxx.xxx/~username instead of domain name.
In a couple of those sites i use htaccess, which refuce to work at all.
Could it be the lack of proper domain name?
No, its more likely that there is a server config problem, or that mod_rewrite is not supported on the new server.
Unless either of those are true, then mod_rewrite should still work, with the possible exception that your hard-coded external redirects would still go to the old server.
On some servers, you must add
Options +FollowSymLinks
Jim
Instead of using, for example:
RewriteRule ^foo\.html$ http://example.com/bar.html [R=301,L]
RewriteRule ^foo\.html$ http://%{HTTP_HOST}/bar.html [R=301,L]
You asked specifically if the domain name affected mod_rewrite, and I replied as quoted above -- Basically, No.
But what may affect the code is the /~username subdirectory-level added to your URL. Your rules would need to take that into account. Look at the RewriteBase directive for a possible solution.
Jim