mod_rewrite is a URL rewriting module for the Apache web server. It is commonly used for so-called "pretty" URLs because of its ability to redirect on the server side (transparent to clients and their browsers), but also provides the power and flexibility to perform various request handling tasks ...
0
votes
1answer
42 views
Using Apache's rewrite module to set up local host names for development
I have several websites on my development machine under Apache's htdocs folder. Apache Directory root is htdocs, but I want to be able to access each different site there by individual domain names. ...
0
votes
1answer
16 views
.htaccess language redirects with seo-friendly urls
How do I setup my .htaccess file to detect several languages, and redirect them to specific seo-friendly urls?
Basically every url needs to go to index.php?lang=(...)
So, for English language ...
0
votes
1answer
21 views
.htaccess ReWrite wildcard folder paths from host
My desired result is change a file to root / from a N number of paths.
For example:
www.host.com/a/b/c/e/f/g/images/1.jpg, where A~G is not always given.
Result:
www.host.com/images/1.jpg
This is ...
1
vote
1answer
56 views
What's wrong with my mod rewrite for GEOIP based on location?
I'm a bit of a newb in modrewrite but used it successfully on my server before.
I successful installed the module on my apache server and tested out with PHP test page(it correctly returned my area ...
0
votes
0answers
26 views
Configuring dnsmasq to properly work with mod_rewrite on Mac OS X Mountain Lion
I read an article on the echoditto blog and followed the recommendations for setting up dnsmasq on my mac using homebrew. Now I am having an issue I cannot resolve, and I need help, because it has ...
2
votes
1answer
49 views
GeoIP and Mod_rewrite: Should I use latitude or city/town?
My boss wants to change our site to one domain with different sub domains being redirected by location to appropriate business site location.
Issue is, these locations are only 100+ miles away from ...
1
vote
1answer
52 views
.htaccess problems with redirection
I apologize ahead of time that this might be a common question, however I've spent 3-4 hours already on solutions which don't quite fix the problem.
I have a site and it is moving to a different ...
1
vote
2answers
49 views
“pretty urls” with only JavaScript content changing
I have a small webapp that uses a single HTML file, but accepts any URL in the directory. I'm using mod_rewrite to make all of these send index.html.
The index page may be accessed at, for example, ...
2
votes
2answers
259 views
Mod-rewrite rule broken after host upgrade to Apache 2.4
I use the following code on my site to remove php extension from links:
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond ...
0
votes
0answers
45 views
Clean URL using index files or mod_rewrite
Is it better to make clean URL's using index files in directories or simply using mod_rewrite rules to remove the file extensions?
1
vote
1answer
113 views
Mod rewrite is not working or doing anything
So I've used an online .htaccess editor and it's not working for some reason on my test server, here's the content of my .htaccess file.
RewriteEngine On
RewriteRule ^Page/([^/]*)/$ /?Page=$1 [L]
I ...
1
vote
2answers
77 views
One .htaccess file with rewrite rules for all domains
Our server is configured with multiple domains which reside in subfolders of the public_html folder. So domain1.com is located in /home/user/public_html/domain1.com and domain2.com is located in ...
1
vote
2answers
18 views
Setting up mod rewrite
I spent hours in finding how to make my url pretty but no luck.
I am hosted in DreamHost and using php under fcgi.
I'm triying to make my:
...
1
vote
1answer
44 views
mod_rewrite doesn't work at all
I have my small website (made for study purposes) on localhost and I am trying to get .htaccess working (note that I am a complete beginner to .htaccess). So far, I have discovered that .htaccess is ...
1
vote
0answers
102 views
Is my .htaccess rule creating an infinite loop?
Whenever I type a made up address that includes a directory index it removes it. The problem is when the the address includes a forbidden subdirectory. It reduces itself until it hits forbidden. How ...