Skip to main content

Questions tagged [mod-rewrite]

mod_rewrite is an Apache module that allows for server-side manipulation of requested URLs.

0 votes
0 answers
14 views

need help - htaccess URL rewrite with query string

Disclaimer: I'm a semi-skilled novice, I've tried a few things but I'm missing something. My site is running a vBulletin Forum and nothing else. I recently upgraded my vBulletin version and moved the ...
JimHegs's user avatar
-1 votes
1 answer
75 views

Test a website without changing DNS settings

I need to test a website before changing DNS records. There are tools such as Skipdns.link and in the past hostcx. I need this but without the limitation of skipdns.link. For example all URLs of ...
Noob's user avatar
  • 97
4 votes
1 answer
79 views

Case insensitivity for Cyrillic characters in Apache .htaccess RegEx does not work

Consider the following RewriteRules: RewriteEngline On RewriteRule ^services$ services.php RewriteRule ^новости$ news.php What they achieve is that www.example.com/services loads the content of ...
plsssineedheeeelp's user avatar
0 votes
0 answers
50 views

Using environment variables and a redirect loop to force-clear a 301 redirect

We mistakenly used a 301 redirect on a very important page, and now that we want to actually use the page, many users' browsers have the 301 stuck in their cache. The problem is that the destination ...
Sean Kendle's user avatar
3 votes
1 answer
452 views

How to match beginning of file name using htaccess

I am attempting to modifying my .htaccess file within a specific directory. If a web user attempts to find any file in this directory that may be named like the following options, I want them to be ...
klewis's user avatar
  • 133
0 votes
1 answer
37 views

apache redirect/rewrite http to https with many virtualhosts

I have an apache webserver that has about 150 VirtualHosts spread out over 9 IP addresses. I'd like to redirect or rewrite http connections to https. The solutions I've found have the rewrite/redirect ...
user1311554's user avatar
1 vote
1 answer
228 views

Creating a .htaccess in a subdirectory causes rewrite rules in higher level .htaccess to stop working

Sorry if this has been asked/answered before, but I was not able to find an answer to this particular problem. If I create a .htaccess file with a simple rewrite rule, that rule works. If I create ...
KBM's user avatar
  • 13
0 votes
1 answer
113 views

Rewrite urls only for certain folder and remove parts of the url in Apache

I have an old project in PHP which I'm trying to modernize. The routing of the old project is just files on the server which you'd access via the url. So for example a file placed in folder/subfolder/...
Andrew's user avatar
  • 113
1 vote
2 answers
512 views

Apache Rewrite Engine redirect all request to index.php

I have a PHP web application on a Apache Web Server. The path to to web application on the Server is: /var/www/html/intern/organisation/example_app The URL to the web application is: https://www....
Mario's user avatar
  • 11
0 votes
0 answers
74 views

Apache custom rewrite rule, using code

I would like to have Apache handle some custom URL rewrite code that I have. This code rewrites the following urls: https://www.example.com/request?data=SOMEDATABLOB into urls pointing to PHP pages. ...
andynewman's user avatar
0 votes
1 answer
53 views

Content negotiation, send webp request to Symfony when webp file does not exist

On Apache Httpd 2.4, I know that from a .htaccess file I can do this RewriteCond %{HTTP_ACCEPT} image/webp RewriteCond %{DOCUMENT_ROOT}/$1.webp -f RewriteRule (.+)\.jpg$ $1.webp [T=image/webp] in ...
nulll's user avatar
  • 529
0 votes
0 answers
231 views

Intercept HTTP POST response from Reverse Proxy in Apache

I have following configuration in my Apache server and requirement is to intercept HTTP POST request to /api/submit endpoint and trigger a CURL request to a remote URL before forwarding it to backend ...
user8373873's user avatar
0 votes
0 answers
151 views

Apache2 folders redirect to IPs

I have installed Apache/2.4.56 (Debian), a noip URL and severals LXC containers. I need to access to the web apps inside the LXC containers: example.com/app1 -> LXC container 1 (with Zend2) example....
Lethal's user avatar
  • 1
0 votes
1 answer
183 views

Use ProxyPass only if remote address is in subnet

I have a php application running with a mostly default config that lives in var/www/html/app: <VirtualHost *:443> ServerName myhost.com DocumentRoot /var/www/html <Directory "...
GammaGames's user avatar
0 votes
0 answers
83 views

In what order does Apache evaluate `RedirectRule` when provided by virtual host, directory context and .htaccess?

I have several RewriteRule inside <VirtualHost>, inside the <Directory> directive which belongs to the web root of said <VirtualHost> and inside .htaccess of that directory. Question:...
user2690527's user avatar

15 30 50 per page
1
2 3 4 5
150