URL rewriting module for Apache web servers

learn more… | top users | synonyms (1)

0
votes
1answer
42 views

Redirect to new domain and preserve username

I recently switched to a new domain for a version control server I run. The server is usually accessed with a username included in the url such as https://userinfo@sub.olddomain.com/some/stuff. I ...
0
votes
0answers
85 views

Third level domain and redirect

I have a domain like mydomain.com I have bought blog.mydomain.com I want that when people hit blog.mydomain.com, they get redirected to mydomain.com/blog. What I am trying is the following ...
0
votes
1answer
196 views

Apache2: Trying to map a subdomain to a subdirectory

So basically I want to have: sub.domain.com/anything -> domain.com/asub/anything I'm a bit new to this and a bit confused. The first thing I did was configure my DNS settings so sub.domain.com goes ...
0
votes
1answer
316 views

Apache .htaccess rewrite php to js and execute js file as php script

I have the folowing rewrite rule in my .htaccess file RewriteRule ^js_([A-Za-z0-9\.\_\-]{1,50})\.php$ libjs/misc/$1.js so js_messages.php url links to libjs/misc/messages.js file It's working ...
1
vote
2answers
238 views

Alias or redirect or rewrite

Roundcubemail and Owncloud folders live on the document root but because of the limitations of the Roundcube OwnCloud Plug-in I have to organise the vhosts as below. $rcmail_config['owncloud_url'] ...
0
votes
2answers
316 views

How do I configure my httpd rewrite/proxy to direct app1.example.com:443 to localhost:8080 and app2.example.com:443 to localhost:8081?

I have two Tomcat instances, one running on port 8080 and the other running on 8081. The both have deployed a web app called app.war but they are separated not only by different ports, but different ...
2
votes
2answers
383 views

Use subpath internal proxy for subdomains, but redirect external clients if they ask for that subpath?

I have a VirtualHost that I'd like to have several subdomains on. (For the sake of clarity, let's say my domain is example.com and I'm just trying to get started by making foo.example.com work, and ...
0
votes
2answers
814 views

Configure mod_wsgi WSGIScriptAlias with mod_rewrite

I want to redirect ex.com to www.ex.com but I still want www.ex.com/ to point to my app.wsgi without it showing up in the url. When I use the conf below and I go to ex.com, I get a 404 error saying ...
0
votes
1answer
254 views

htaccess rewrite condition old site to new site with querystring

I am not even going to pretend to fully understand how htaccess rewrite conditions work. I've been working on this for a while searching and searching. I have an old Wordpress site www.old-site.com ...
0
votes
0answers
697 views

Rewrite URL and keep POST data

We recently setup SVN for our web development. We'd like to be able to browse different branches/tags/trunk based on the URL you input on our dev server. So, for example, ...
1
vote
2answers
473 views

Server remembering old rewrite rules, even when I remove htaccess

I have set up a development server with Ubuntu and LAMP, but for some reason the .htaccess is acting strange... There is a site on there with a set of rules, when I comment them out they still work, ...
0
votes
1answer
251 views

Trouble configuring virtual host to allow standard wordpress mod_rewrite for permalinks

I'm having a little trouble getting the standard mod_rewrite that wordpress generates in my directorys .htaccess file to work correctly. The server I'm using has a virtual host set up on it by ...
2
votes
2answers
3k views

Request exceeded the limit of 10 internal redirects

so here is the error [Mon Sep 30 00:09:53 2013] [error] [client 66.249.66.205] Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' ...
0
votes
3answers
383 views

Mod Rewrite appends Document root in rewrite rules [duplicate]

Previously my host provider gave an option of setting up rewrite rules in apache configuration files. At that time below rule worked fine. # Non WWW URLs to WWW URLs RewriteCond %{HTTP_HOST} ...
0
votes
1answer
113 views

Apache Hotlink Prevention not Working

I have been trying to prevent hotlinking of images on a domain of mine without any success. I have added the following to /etc/apache2/httpd.conf RewriteEngine On RewriteCond %{HTTP_REFERER} !^$ ...
0
votes
1answer
198 views

Jetty Rewrite NoSuchMethodException

I tried to configure jetty rewrite rules. I used code from the example here: http://www.eclipse.org/jetty/documentation/current/jetty-handlers.html#d0e10798 but when I try to run it I get: 2013-09-29 ...
-1
votes
1answer
88 views

Nginx redirect sub.domain.com/users/page/somename to somename.sub.domain.com

I've been trying to redirect http://sub.domain.com/users/page/somename to http://somename.sub.domain.com etc. Any pointers?
0
votes
1answer
157 views

Apache - Return 404 for all execept selected

I am seeking for method to prevent access to Wordpress admin folder "wp-admin", but also i need apache to generate 404 error (Not found) for all, but not selected IPs. I found this post Returning 404 ...
1
vote
1answer
241 views

htaccess RewriteRule force end of execution Apache 2.2

Hi I have written some rewrites, but from what I can tell from the logs it seems that the rules keep executing and so, although the correct result is achieved mid-execution, the final rewrite is ...
0
votes
1answer
2k views

RewriteBase rule works in .htacess, but not in httpd.conf (inside <Directory …>)?

Let me explain by example... File: /var/www/example.com/public/wp-content/cache/minify/.htaccess <IfModule mod_rewrite.c> # THIS WORKS... RewriteBase /wp-content/cache/minify/ ...
0
votes
1answer
59 views

htaccess rules unexpectedly forcing download of gzipped index.html [duplicate]

I'm trying to set up SSL on a Wordpress site. The SSL certificate does not cover both www. and non-www. versions of the URL, so I'm trying to simply redirect everything to https://domain.tld with ...
-3
votes
2answers
455 views

Mod Rewrite code with out changing the url in address bar

I When I call http://www.mysite.in/abc/xyz it shoud show up http://www.mysite.in/abc/xyz/index.php but the url shout not change in address bar and it should work with out "/" in the address. Please ...
-1
votes
2answers
77 views

Website link with out “/” [duplicate]

My Apache 2.2 is running on port "8080" I want to call my site url http://www.example.in:8080/abc/xyz.html/index.php (xyz.html is a folder) as .... http://www.example.in:8080/abc/xyz.html Can ...
0
votes
1answer
338 views

How to rewrite /index.php to /app.php [duplicate]

I have this in my .htaccess file: <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC] RewriteRule ^(.*)$ http://%1/$1 [R=301,L] RewriteEngine On ...
-1
votes
1answer
29 views

redirect / to /?C=N;O=A [duplicate]

I want to be able to use IndexOrderDefault Descending Date for all of my sub-folders, but I want to the first page to be sorted by name (A-Z) I read ...
0
votes
2answers
819 views

LDAP Auth proxy adding headers according to LDAP groups

I'm trying to setup some WebSSO mechanisms, that allow my customer to authenticate people against internal Active Directory and then add secure (https) headers containing credential information. ...
0
votes
2answers
1k views

How to change NGINX server name

In the Apache web server we can change the server signature (Apache Name) using mod_rewrite. For example - ...
0
votes
1answer
160 views

redirect a directory to a new domain without touching the main website

I would like to redirect https://mineyourmind.de/forum to https://mineyourmind.net/forum . Every rewrite rule I could google didn´t work, they also redirected the main domain (mineyourmind.de). Im ...
-1
votes
1answer
278 views

You don't have permission to access /on this server

I created a form in joomla with 2000 fields but when I submit the form it gives me: error-- You don't have permission to access /en/soccer-player-update on this server. Additionally, a 404 Not Found ...
0
votes
1answer
891 views

Apache mod_rewrite: how to handle slash in URL?

I have a following URL structure: http://mysite.com/movies/index.php?id=123 I want to get rid of index.php?id=123 and instead use the following URL: http://mysite.com/movies/123 I came up with ...
0
votes
1answer
178 views

Are there security concerns when using Apache's mod_proxy as a gateway?

In order to cope with same-origins policy for AJAX calls I want to allow for mod_rewrite and mod_proxy to handle these calls in a similar way as described in another answer: rewriteEngine on ...
0
votes
0answers
88 views

How do you exlcude a sub-directory from an Apache rewrite ruleset?

I have a multilingual site with the root being English and a sub-directory (/es/) being a human translation into Spanish. Instead of manually updating all URLs, I have a opted to use mod_rewrite to ...
0
votes
1answer
93 views

Apache reverse proxy logic based on arbitrary header

I have apache running on a natting fw, that authenticates, reverse proxies, and provides an ssl wrapper for 2 webapps on the back end. This works with virtual hosting and proxies back based on the ...
0
votes
1answer
122 views

URL rewriting/redirecting with two parameters

Basically, I want to have this URL: http://domain.tld/auth.php?state=somestate&token=somelongtoken rewritten/redirected into this: http://domain.tld/auth/validate/somestate/somelongtoken I ...
1
vote
0answers
199 views

htaccess, errordocument and joomla rewrite

I need to setup a 404 error handling in my .htaccess, besides handling some 301 redirects for the links of an old website. The new site is made with Joomla, the old site was written in asp. Sef urls ...
0
votes
1answer
283 views

SSL/TLS Client certificate Authentication using RewriteCond and Rewrite Rules to perceptively redirect traffic not authorized

I finally end up to write here because I´m badly struggling against apache, SSL/TLS and a client certificate authentication that should use the certificate´s Serial Number to restrict access to a ...
2
votes
1answer
176 views

Why does mod_rewrite not reprocess rewritten paths?

I'm doing a path rewrite to set and environment variable that will cause mod_jk to use a specific JBoss server. Works perfectly with any of the application paths. When I try our monitoring servelet ...
0
votes
1answer
47 views

add word in url using .httaccess

Right now i am accessing abc.xml from test directory as below http://localhost/test/abc.xml I want to redirect the above url as below http://localhost/test/test.php?abc.xml ...
1
vote
1answer
240 views

RewriteRule not working with mod_userdir

My setup: Ubuntu 13.04 Apache/2.2.22 (Ubuntu) PHP 5.4.9-4ubuntu2.2 -- $ ls /etc/apache2/mods-enabled/*.load alias.load auth_basic.load authn_file.load authz_default.load ...
3
votes
2answers
689 views

Apache configuration - rewrite rule for all virtual hosts

I have the following configuration with 2 virtual hosts on my Apache: www.domain.com and res.domain.com. The first one is open the second is limited to registred users. <VirtualHost *:80> ...
0
votes
2answers
62 views

Apache Proxy to show another Website

I need to proxy the URL http://de.domain.com/article1/foobar/ to http://de.foobar.domain.com/article1/. How can I do this within getting and setting the subdomain language part? Examples: ...
1
vote
2answers
75 views

Can you please explain substitution in RewriteRule

I have the following statements in an .htaccess file RewriteCond %{HTTP_HOST} ^myOldDomain\.com$ [NC] RewriteRule ^(.*)$ https://myNewDomaink.com/$1 [R=301,L] It works fine. I basically found some ...
0
votes
2answers
426 views

Main domain is redirecting to subdomain

I've a domain domain.com and made one sub domain 'forum.domain.com'. I'm using Apache2 and added one A record to the dns records and made virtualNameServer as: <VirtualHost *:80> ServerName ...
2
votes
1answer
141 views

Rewriting the whole URL using mod_rewrite

I know how to use Apache's mod_rewrite in a common way but now I'm trying to use it in a different way which was not a success to this moment. Here's what I wrote: RewriteEngine on RewriteMap ...
0
votes
1answer
43 views

Drop Port Number on Apache Redirect Rule

I am trying to figure out a rewrite rule to drop port 81. I am using no-ip and so the request hits port 81 and then i have a rewrite rule to redirect to SSL. Now it looks like https://example.com:81 ...
1
vote
1answer
602 views

Make mod_rewrite rules process before fcgi sees the request

Is there a way to have the mod_rewrite rules in my .htaccess file take effect before PHP behind fcgi sees the request? I have an email validation link that I want to redirect from root to the login ...
0
votes
1answer
49 views

local apache2 adds trailing slash

I am currently trying to get a webpage of mine running on my local machine. Strangely though, albeit I do use the exact same Directives and RewriteRules, what works on my server, does not work on my ...
1
vote
3answers
501 views

Index.php downloads instead of opening

Ok, so I have a server at work that I am setting up sites on. It has a Wordpress site in the root, a phpBB forum in a child directory, and a support site in another directory. I'm able to access both ...
0
votes
1answer
34 views

Inspecting apache mod_rewrite

I want to do something simple with apache mod_rewrite. And guess what, it doesn't work. Had I been in a "sane" environment, maybe I would get an error and a stack trace. Or maybe I could use a ...
1
vote
2answers
1k views

Using Apache httpd to redirect context path?

I'd like to proxy http://localhost:1006/ as http://example.com/public/ to the outside world. Here is my configuration: RewriteEngine On # Append a slash if necessary RewriteRule ^/public$ public/ ...