URL Rewriting maps an incoming URL to a modified URL, so that the request is processes as if the original request was made to the modified URL. This is often used to provide more search engine friendly URLs.

learn more… | top users | synonyms (5)

0
votes
0answers
3 views

How to debug opencart redirect loop?

I'm attempting to redirect an opencart website from http://domain.com to https://domain.com, i have tried the following with different variations: RewriteCond %{SERVER_PORT} !^443$ or RewriteCond ...
-1
votes
0answers
19 views

Issue with VirtualHost on Apache?

I have an Apache VPS server and I have a project in a subfolder of my site (example.com/projects/my-project). I set up a VirtualHost for this project on /etc/apache2/sites-available/000-default.conf. ...
0
votes
0answers
25 views

Redirecting to maintenance page and banning IPs in nginx

I'm new to nginx and would appreciate it if you can offer assistance. I'm trying to first, rewrite all requests to server ip 1.2.3.4 to example.com/maintenance.html. I have put the following block in ...
2
votes
0answers
28 views

Apache rewrite works under FreeBSD, not under CentOS

I have 5 production servers which are running FreeBSD 9.2, but we are planning on transitioning to CentOS. Because of this, I am attempting to set up some virtual machines to emulate our production ...
0
votes
0answers
29 views

Nginx redirect or rewrite with folder

I have a virtual machine with an apache which serves a web application at https://my.ip.address/web/index.hml (internal). At the router/firewall is a nginx running which works as an reverse proxy with ...
-2
votes
0answers
24 views

Nginx allow one directory, one path, rewrite all others to php script [closed]

My public_html directory: Classes/ Data/ Private/ Public/ Internal/ Ajax.php Main.php Private.php ... I want to make nginx work with following rules: Allow indirect acces (with X-Sendfile) to ...
-2
votes
0answers
17 views

nginx:- rewrite/mask ip to domain name [closed]

Here i want to access ems.example.com (51.23.15.123). it shows 51.23.15.123 while entering ems.example.com. so i want to mask that ip in front end. Here i tried... upstream servers{ server ...
0
votes
0answers
8 views

IIS Setup Redirect traffic from webserver to app server

I have done quite a few setup which involved hosting applications in IIS and configuring them accordingly, but now I have a different situation ... I have 2 web servers which don't host any ...
1
vote
1answer
71 views

NginX rewrites and absolute resource paths

On my domain, I have a subdomain for Meteor applications, say http://meteor.example.com/ Under this, I would like to put individual applicaions, with an URI for each. Say the meteor application ...
2
votes
1answer
23 views

Nginx redirect to port specified in URL

Is it possible to use Nginx to proxy from a URL like this: http://example.com/service/1234/foo.php?... to an internal service like this: http://example.com:1234/foo.php?... That is, extract a ...
-1
votes
0answers
44 views

Nginx rewrite URL for webpage and links

server { listen 443; server_name myserverone; ssl on; ssl_certificate cert.pem; ssl_certificate_key cert.key; location / { rewrite ^ ...
0
votes
0answers
57 views

nginx catchall reurns bad gate way with $host in proxy_pass

I am currently using the following virtual server proxy setup on my development environment the defined virtual servers work fine but i am coming up with a bad gateway error when i hit my catchall ...
-1
votes
2answers
26 views

Nginx rewrite with Server_name as underscore

We have nginx config with server_name as underscore. How do I rewrite from http to https. server { server_name _; rewrite ^/(.*) https://$server_name/$1 permanent; } This returns error as http://_/ ...
0
votes
1answer
28 views

Ngnix rewrite with catchall server_name

Im trying to do a rewrite based on a catchall server name. So I would like any domain that hits this server for example demo.example.com to be rewrote to example.org?site=demo.example.com ...
1
vote
0answers
23 views

IIS URL Rewrite to act as 404 handler

How can I use the URL Rewrite module in IIS to mimic a generic 404 handler? It is easy enough to set up rewrite rules that match a specific pattern, but what I want to do is to set up a rewrite rule ...
0
votes
1answer
36 views

What is the nginx version of these .htaccess rules? [closed]

How should I rewrite this htaccess rules to nginx kind of rules: RewriteCond %{REQUEST_URI} !^/?puppy/index.php$ RewriteRule . /puppy/index.php
0
votes
0answers
27 views

Exceptions in redirection in URL in IIS Rewrite module are ignored

I have a new site https://www.NewSite.com and I would like all the traffic to my old site https://www.OldSite.com to be redirected to the root of my new site https://www.NewSite.com/, with some ...
0
votes
3answers
68 views

Rewrite in Nginx Does not work for POST request

I have two VPS(one is for fail over), both running Nginx as a Load balancer for backend servers. Also, I have Enabled and configured SSL for my domain(registered on GoDaddy.com) on Nginx. Since I am ...
0
votes
0answers
45 views

Nginx: Redirect subdomain to path

This is very similar to the question at http://stackoverflow.com/questions/14491944/nginx-convert-subdomain-to-path-component-without-redirect, however I need it to be a permanent redirect (not ...
0
votes
1answer
27 views

How to rewrite this url in NGINX

I have multiple urls in this manner. http://domain.com/something/static/variable/ But now I want to redirect the url above to http://domain.com/anything/static/variable/ I tried location ...
0
votes
2answers
115 views

Redirect traffic based on url to different ip address maintaining port and url information [duplicate]

We have a QA version, a UAT version, and a DEV version of webapp. Users need to access these via http://uat.company.com:41002/webapp, http://qa.company.com:41002/webapp, and ...
0
votes
2answers
55 views

Apache mod_rewrite : RewriteRule to pass requests tomcat application [duplicate]

I am having difficulty defining a correct RewriteRule to forward requests to an application running in tomcat. I have apache with mod_rewrite enabled as well as tomcat setup with an application ...
0
votes
0answers
24 views

IIS Reverse proxy and URL Rewrite don't work

I did following steps: Installed all neede features to IIS (URLRewrite 2.0, ARR, ...) Created default MVC Web Application in VisualStudio Added this web app as new site to iis (I can access it by ...
1
vote
1answer
14 views

URL rewriting a specific directory

I want to rewrite the URL when receiving a request that is not a file and either for directory subdir or not a directory at all. E.g. (!file) && ( (subdir ) | ( !directory ) ) Here's my ...
0
votes
1answer
56 views

nginx: url rewriting not working

I'm using Jelastic with nginx 1.6.1 and would like to use friendly urls without the .php extension. So if someone visits for example https://domain.com/faq.php nginx should rewrite it to ...
1
vote
1answer
43 views

Nginx rewrite module not working

I've read a lot of topics about it, but couldn't solve my problem. After moving from APache to Nginx I can't set rewrites to handle my forums friendly urls. My forums is in /forum/ location of the ...
0
votes
2answers
57 views

Nginx rewrite: replace - with /

I set up ghost blogging platform. It doesn't allow to insert «/» signs in article links, but I want them to appear in my links, so I want them to be fixed with nginx rewrites. The link in a browser ...
0
votes
1answer
19 views

Nginx Rewite - Matching End Urls not working

Trying to redirect urls like these: http://example.com/vehicles/cars/author/xyz http://example.com/plane/author/xyz to these: http://example.com/profile/xyz I tried this Nginx Rewrite, but its ...
0
votes
1answer
21 views

Nginx: redirecting a directory to a virtual server

I have two Nginx virtual servers: server { listen 80 default_server; server_name antergos1; root /data/ } server { server_name nagios; root ...
0
votes
0answers
27 views

How to rewrite request for subdirectories using apaches' mod_rewrite?

My document_root is /home/john/public_html. I need the URL example.com/subdir/index.php to be handled by the file /home/john/public_html/index.php. This is what I put in ...
0
votes
1answer
33 views

Block a unique hash in URL through NGINX

I need to block a hash which is inside a URL through nginx. The URL which requires to be blocked is ht tp:/ /mp3s tri ng.c ...
0
votes
0answers
44 views

Nginx redirecting site index requests

Existing functionality: try_files along with rewrite are being used to allow requests for foo.html and foo/ to redirect to foo. Problem: If I specify try_files $uri.html $uri @noextension =404;, then ...
1
vote
0answers
33 views

Convertion of htaccess rewrite rule to nginx [closed]

Through searching the internet with "converting htaccess to nginx rule" I came up with anilcetin and winginx .htaccess to nginx converter which I doubt it doesn't correctly output what I need. Which ...
0
votes
1answer
53 views

Nginx rewriting files that do not exist

Nginx is returning the site root index instead of a 404 response for non-existent files, i.e. attempting to rewrite files that do not exist which is undesired. While I see the topic was answered here, ...
0
votes
1answer
33 views

Nginx: How do I point the root to a Ghost blog located in a subdirectory?

I have installed Ghost inside a blog/ directory in my site's root. The site works as domain.com/blog/ and serves static files from public_html/ directory (including index.html). I would like to have ...
0
votes
0answers
19 views

Mod-rewrite with GET [duplicate]

I'm trying to get my htacces to rewrite URLS with GET parameters but hopelesly failing. I'd like for this: domain.com/landingpage?variableone=true&variable2=false to be converted to this: ...
0
votes
0answers
49 views

Nginx Rewriting, Renaming and Redirecting to another Folder

I am trying the following steps to my old urls before redirecting them: 1) Rewrite all urls inside a folder by replacing underscores to hyphens 2) Remove the old folder name 3) Try the new urls in ...
2
votes
1answer
78 views

Nginx treating old PHP urls as Files

Having a very hard to trying to figure this out. I have changed my website from another platform to Joomla and now Nginx is unable to handle old urls. My Old Urls were like this: ...
0
votes
0answers
53 views

IIS URL Rewrite not adding trailing slash

I have a Windows Server 2012 R2 acting as a reverse proxy for an apache server on another local server. When I access the site with example.com/myapp/ It works fine but if I go to example.com/myapp ...
0
votes
1answer
56 views

How to create Multiple Parked Domains in Nginx Server Block

I have bought multiple domain names for my website. Right now, I redirect these parked domains (the domains pointing to my nginx ipaddress) like this: server { server_name example.com ...
0
votes
1answer
36 views

Nginx Re-write: Different URL based on incoming URL format [duplicate]

I have a server that will have 2 different types/formats of requests coming in. Both request URL's will start with: http://myredirect.mycompany.com/browse/. After '/browse/' it will either be a ...
0
votes
1answer
19 views

mod_rewrite combine these two rules into one

I have two rules that currently function as they should, but I feel like they can be consolidated into one for the benefit of a smaller config to maintain and less rules to process for each HTTP ...
0
votes
1answer
99 views

Rewriting ASCII-percent-encoded locations to their UTF-8 encoded equivalent

For example, “å” can be encoded as /%E5 and /%C3%A5 (utf-8). All my filenames are UTF-8, so the ASCII variants return a 404. I want both variants to work. I have tried rewriting the incorrect URLs to ...
0
votes
1answer
38 views

web.config URL access and rewrite

I'm trying to clean up some URLs to a bunch of PDF files. Right now, you access a PDF by visiting the following: http://www.mywebsite.com/sites/default/files/reports/2010_Audit_Summary_Report.pdf ...
1
vote
1answer
63 views

Nginx rewrite part of URL

i'm trying to make a redirects from URL's with option ID to URL's with option URL_key i've assigned. I have two column table with ID i'd like to substitute and URL_key as substitute. 11337 bar ...
1
vote
0answers
60 views

Rewrite a url to a a new URL and then send the new URL to a PHP script

I have URLs that contain a cache busting string. I want to rewrite these URLs without the cache busting string, and then send the rewritten URLs that match a certain criteria (e.g. audio/video files) ...
1
vote
1answer
83 views

nginx location and root settings dont work

I am trying to rewrite every file after cdn.minora.me/forum/ to another directory: server { listen 443 ssl; listen [::]:443 ssl; ssl on; ssl_certificate ...
0
votes
0answers
29 views

nginx rewrite keeping subdomain

I have a nginx server and several domains connected to it. I would like to replace all http request with a https request to one specific domain (for which I have a certificate). Example: Say I have a ...
0
votes
0answers
56 views

apache mod_proxy_html to rewrite wsdl

I'm trying to configure mod_proxy_html on apache httpd 2.4.9 to rewrite an element of an xml document returned from a webservice that is reverse proxied using mod_proxy_balancer <description ...
0
votes
0answers
145 views

IIS 8 Win 2012 R2 - Rewrite redirect not working, page not found, address not changing

I have an MVC4 app and trying to rediret pages so that both http://example.com/about and https://example.com/about direct to https://example.com/about (where about could be any other page also). I ...