All Questions
Tagged with apache-2.4 redirect
161
questions
0
votes
0
answers
41
views
HTTP to HTTP Apache2 Rewrite not being used
I want all traffic sent on HTTP redirected to port 443.
I curently have a Rewrite rule set up for port 80 in the sites-available apache2 directory but when I go to that address on that port it still ...
0
votes
1
answer
129
views
Application actions based on URL
I am sorry if this question was already asked, but I do not know how to frame it differently - none of my searches found something that answers this.
I am currently using Windows 11 and XAMPP, with ...
0
votes
1
answer
104
views
Weird 301-redirect to http from https only happening with CF as proxy on /wp-admin on www subdomain
I have a wordpress blog on an EC2 instance on AWS using the AMI image aws-marketplace/bitnami-wordpress-6.3.2-6-r09-linux-debian-11-x86_64-hvm-ebs-nami-7d426cb7-9522-4dd7-a56b-55dd8cc1c8d0
In ...
1
vote
0
answers
136
views
Avoiding redirect server's url to www for specific url path
I want to enable auto-verification of deep links in Android for which I need to host the file assetlinks.json on my server https://mycompany.com. This will allow auto-verification of my deep links ...
0
votes
0
answers
49
views
Test Page Apache httpd on docs.domain.com
I have a wordpress website server running on linux.
I have a issues when I enter docs.domain.com it opens a Test Page Test Page pic . So my target is when users enter https://docs.example.com to ...
1
vote
0
answers
605
views
Apache Server Forward Proxy : How to redirect to a custom page?
On Apache server (Xampp) I have make a forward proxy for firewall filtering that works well, but I don't understand how to use RewriteRule to redirect a forbidden url to a custom error page.
I wish to ...
0
votes
2
answers
100
views
Path not excluded by mod_rewrite config
I am trying to roll my own vhost config to handle certbot/letsencrypt. I want to redirect anything other than requests to /.well-known to HTTPS. But the exception for .well-known is not working; ...
1
vote
1
answer
491
views
Apache RedirectMatch not matching double slash
I want to redirect URLs with multiple consecutive slashes (e.g. //) in the path to have only one consecutive slash, e.g.
https://example.com/a//b/c/ → https://example.com/a/b/c/.
My .htaccess file ...
1
vote
2
answers
888
views
Apache rewrite rule for a folder to a different domain
I need to redirect all requests concerning a folder to another (old) web server called www2 keeping the entire original path, for example
https://www.example.org/thisfolder/maps/map.jsp?id=2345
must ...
1
vote
1
answer
176
views
httpd redirect one port number to another
We are trying to redirect requests on port 8555 to port 8443. In our httpd.conf file, we have the following:
<VirtualHost *:8555>
SSLEngine on
# SSL configuration that is irrelevant to this ...
1
vote
1
answer
647
views
Default WordPress .htaccess rewrites causes default server page to load due to no default index page present for the root URL
I could really do with some help here please. I know this is a WordPress issue now through testing.
If I allow .htaccess to process rewrites on my Wordpress sites by adding AllowOverride FileInfo to ...
1
vote
1
answer
491
views
Trapping misformatted paths to Redirect to 404 instead of returning 403
Owing to an error long ago our company web site has been serving image URLs containing a significant amount of white space.
E.g.
http://www.example.com/ /assets/ProductPhotos/...
0
votes
1
answer
110
views
Redirect rules for multiple enviroments
I have written a set of rules for 3 different environments on the same server. In a nutshell I would redirect the users to the Dev, Stage and Prod single sites. Also enforce https and www for the ...
0
votes
1
answer
367
views
Apache2 how to generate random string for subdomain
I want to issue a redirect to a new randomly generated subdomain name for every request I get. Below you can find my vhost configuration. I want to do a redirect towards a subdomain containing some ...
0
votes
1
answer
28
views
http timeout https works - Apache ssl redirect doesn't work
Asking myself this question because it took me very long to figure out and I hope I can help others, to be faster.
On my server https://example.com worked fine and I set up a redirect to make sure it ...
0
votes
1
answer
259
views
How do I redirect a website to local website?
I am trying to make my browser load local website instead of visiting actual website.
I have this httpd configuration
<VirtualHost 140.82.113.4:80>
ServerName www.github.com
ServerAlias ...
1
vote
0
answers
170
views
when it goes to https:/... directly it is missing the referer part
it's all about cookies ,it suppose redirect to ?referer_id=186 every time which is refresh the cookies of new logo but i notices when user delete or clear the history of Brower and try to visit the ...
1
vote
1
answer
539
views
Apache redirect www and non-www with subdomain to non-www https
I would like to redirect www and non-www with a subdomain to non-www HTTPS.
I think this should clarify.
<VirtualHost *:80>
DocumentRoot "C:/www/eshop"
ServerName shop.example....
0
votes
0
answers
46
views
How to configure a redirection just for visitors coming from a specific address?
I've been handed a website using cloudflare workers to redirect a wordpress blog hosted in a subdomain to a subdirectory - for the most part it's a copypaste from this cloudflare article plus an if-...
0
votes
2
answers
2k
views
Apache Proxypass redirects "localhost:port" as url string instead of local service of the port
Environment
Server version: Apache/2.4.6 (CentOS)
I have two servers which are almost duplicates.
aaa.com. and bbb.com.
They have almost same Apache rulesets.
aaa.com. config
<Location "/...
0
votes
0
answers
404
views
www page always returns 302
We are changing our company website, old wordpress website is on old server centos/apache with ip 10.10.10.20 and the new one has different ip 10.10.10.200. The deal was to just edit dns entries, as ...
1
vote
2
answers
2k
views
Forcing HTTP/HTTPS Redirect on AWS LightSail Wordpress Multisite - Not being implemented
I have searched many site and also Bitnami support pages and I was unable to find an answer to this issue I see. I cannot post on Bitnami support cummunity as a new topic as I have just joined :/
I ...
0
votes
1
answer
796
views
Apache2 : 2 php versions in the same VHOST
I am migrating my app from PHP 5.6 to php 8.0 by having a front controller redirecting to my legacy app or my new app depending on the uri.
I tried with alias and it works but I need to keep the exact ...
1
vote
1
answer
2k
views
Rewrite Rule for URL with query does not work
I write the following rewrite rule:
<IfModule mod_rewrite.c>
RewriteCond %{QUERY_STRING} rp=\/knowledgebase\/.*
RewriteRule ^\/customer\/index.php /knowledgebase/ [R=301,L]
RewriteRule ^\/...
0
votes
1
answer
891
views
Apache 410 a URL Without Affecting Sub Paths
I'm trying to kill a URL, so in my .htaccess file, I put:
Redirect 410 /my-path
It works.
If I try to visit:
https://www.example.com/my-path
I get:
Gone
The requested resource is no longer ...
1
vote
1
answer
156
views
Redirect the document root and a specific page only to another domain
Might sound confusing, but what I want to achieve is this:
If the user visits:
www.mydomain.com (with or without www.)
transfer them to:
www.myotherdomain.com/welcome-old-users
At the same time, I ...
1
vote
0
answers
176
views
Apache reverse proxy configuration (/context to /)
I'm having this issue trying to proxy a site to another context on a different domain
What I currently have ?
I have a fully functional web site running on the following URL:
https://helloworld....
0
votes
1
answer
3k
views
Redirect to a URL passed in the query string with Apache 2
I'm pretty newbie in URL redirection, and I would like to create this kind of redirection: http://example.com/?url=http://domain.test/ to http://domain.test/
The result I'm having so far is: http://...
1
vote
2
answers
2k
views
Apache redirect HTTP to HTTPS Redirect or Rewrite?
I have found two way to redirect http to https with apache.
Using Redirect
Redirect / https://mydomain/
Or Rewrite
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/?(.*) https://mydomain/$1 [...
0
votes
2
answers
2k
views
Nuxt.js program not running on the Main Domain with Apache in Ubuntu
I have a Nuxt.js program that I run on Apache in Ubuntu OS. When I port it to a subdomain like www.example.com, it works fine; But when I port it to the main domain such as example.com, my program ...
0
votes
2
answers
396
views
I can´t redirect HTTP to HTTPS in my Apache server proxy
(Sorry for my bad english)
Hi, i know that this is not the first question about redirect to a secure conection in a proxy server but i have no ideas how to resolv it.
this is my config
ErrorLog ${...
2
votes
1
answer
4k
views
Apache2 - default SSL/HTTPS page - aka. <VirtualHost *:443>
This is a very simple question.
I have several websites hosted. Some are HTTP, some are HTTP and HTTPS. It all works.
However, if I mess up an SSL site by pointing a domain at my server where the SSL ...
1
vote
1
answer
344
views
Does an .htaccess redirect to a different folder activate the second .htaccess within?
On my apache site, I have the following redirect:
RewriteCond %{REQUEST_URI} !^/web/
RewriteRule ^(.*)$ /web/$1
which redirects from the root directory, to the "Web" directory.
Will this ...
1
vote
0
answers
565
views
Subfolder redirection to another port
There are two services on the server's two ports 192.168.0.42 in the LAN.
80 - wordpress with blog
8080 - java application (chat)
Domain redirected to router which forwards traffic from 80 and 443 ...
1
vote
0
answers
38
views
Combine rewriting and redirection rules in Apache
I have VirtualHost configurations in Apache which used to use the RewriteEngine to do some URL corrections and finally pass control to one (or more, using mod_proxy_balancer) Zope/Plone instances.
Now,...
0
votes
1
answer
28
views
How to fix redirection for query?
I have old and new URL paths, I want to write redirection rules, so 2 versions of old paths with query strings:
/cgi-bin/something?123
/cgi-bin/something?keywords=123&offset=120
are both ...
2
votes
1
answer
286
views
Dynamic DocumentRoot Based on SSL (Client Auth.)
I currently use Client SSL authentication to protect sensitive content. Users are required to import a certificate into their browsers that we generated using OpenSSL. When a user visits the website, ...
0
votes
1
answer
201
views
Apache/IIS redirect subfolder with same domain name
I have 2 servers :
-1 in IIS
-1 in apache
I have a domain like example.com .
i would to make some redirection so when you enter http://example.com you are going on the IIS server
When you enter http://...
2
votes
0
answers
3k
views
ErrorDocument 400 redirect to different URL without rewrite
I want to implement a custom Error 400 page on my website tikolu.net, to a file called 400.php in a folder called error.
The first thing I tried was to simply place ErrorDocument 400 /error/400.php ...
0
votes
2
answers
256
views
Best method for setting few SSL domains with redirects
I wonder what is "best" and recommended method of setting up SSL domains on single IP, where there are redirects from :80 to :443. This was not entirely covered here, because I need those ...
1
vote
0
answers
210
views
How to set up host redirection in a forward proxy in apache?
I have set up an apache proxy on my dev computer, so that I can redirect all requests to prod.example.com to staging.example.com, for reasons that are outside of the scope of this question. The ...
0
votes
1
answer
1k
views
Apache redirect without port number
This might actually not be possible, but trying anyway: I want to create a container image for Apache without the need to run as root. So I set up the VirtualHost to listen to port 8080 instead of ...
1
vote
2
answers
5k
views
How can I configure Apache to redirect root to a suburi in addition to https redirection?
I have an Apache webserver running a bunch of web apps. I have successfully redirected incoming http traffic to https for every individual app, but I'm having trouble routing ALL traffic coming to the ...
1
vote
1
answer
808
views
Apache redirect all non valid wildcard subdomains to root domain
Is it possible to redirect all 404 subdomain result to the root domain in apache2? Im using a wildcard subdomain entry in my DNS provider, and apache is set to fetch the site in the folder with the ...
1
vote
1
answer
1k
views
Apache mod_rewrite with Redirect Dropping Authorization Header
I have some Apache mod_rewrite rules set up to redirect Maven deploys from one url/server to another. We're in the process of migrating from Nexus to Artifactory and need these redirects set up so ...
-1
votes
2
answers
2k
views
Apache redirect with HSTS
I need to redirect all for example.com to https://www.example.com with HSTS turned on. How to do it? I got configuration in vhost80 and vhost443. What to fix in this code:
in vhost 80
RewriteCond %{...
1
vote
1
answer
5k
views
Apache redirect to wrong Vhost while redirecting to https
Problem
Accessing studentmossa.domain.comresults in a redirect to server.domain.com.
Short valuable information
I am running Fedora 31 (kernel 5.5.15-200.fc31.x86_64) with Apache/2.4.43 (Fedora).
...
0
votes
1
answer
330
views
Apache Virtualhost Redirect HTTPS non-www to HTTPS www not working
I'm having an issue with apache. I would like to redirect:
http://www.example.com to https://www.example.com - ok
http://example.com to https://www.example.com - ok
https://example.com to https://www....
0
votes
1
answer
3k
views
Apache HTTP to HTTPS Proxy Redirect multiple addresses
I need your help.
I have 2 versions of the application running on the Linux machine. Version1 runs on localhost port 5000, version2 runs on localhost port 5001.
I need users to be able to access ...
1
vote
1
answer
866
views
Apache redirect multiple https domains to one https domain using virtual Hosts
I’m running a CentOS Server with apache 2.4 that serves two domains: myurl.domain.com and myurl.otherdomain.com. Using virtualhosts I want all requests to be redirected to https://myurl.domain.com.
...