Questions tagged [mod-alias]

Maps different parts of a host file system into the document tree and it used for URL redirection

65 questions
0
votes
0 answers

Requests go to document root with Apache alias

I have this configurartion ServerName myserver.fr SSLEngine on ProxyRequests On ProxyPreserveHost On DocumentRoot /srv/apache2/htdocs/ Alias /subdomain/ /srv/apache2/htdocs/subdomain/ …
Rafael Angarita
  • 121
  • 1
  • 5
0
votes
1 answer

Apache location overlapping

I'm trying to create an alias to intercept some url to serve from file system directly with Apache 2.4 In my virtualhost, I have: DocumentRoot /var/www/mysubroot I have a location on "/" in order to send all to the apache balancer
DevOps
  • 720
  • 5
  • 16
0
votes
1 answer

Apache Alias directive - not ignore .htaccess files

When using the Alias directive to map a URL to a directory outside the document root, it seems that the .htaccess files in the document root are not applied to those requests. For example, if setting php_flag display_errors off in…
sa289
  • 1,318
  • 2
  • 18
  • 44
0
votes
1 answer

Remove double URL encoding on URL

I have a third-party shopping cart set up on my server using PayPal for payments. When a user completes a transaction they are redirected to the URL https://example.com/?target=payment%255freturn&txn_id_name=txnId.... The correct URL should include…
colincameron
  • 103
  • 4
0
votes
1 answer

Have Apache serve static content instead of forwarding it to Plone (++resource++)

I have a Plone-based site, running behind Apache 2.4, which could perform a little better. One idea is to have Apache serve the static parts of the contents, preventing them from being rewritten for the Plone process, as is commonly…
Tobias
  • 165
  • 1
  • 9
0
votes
1 answer

Why isn't my apache alias working?

Here's my vhost in apache 2.4: ServerName mailcatcher.dev Alias /mailcatcher.dev.png /Users/me/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/mailcatcher-0.5.12/public/images/logo_large.png
Camden Narzt
  • 123
  • 5
0
votes
1 answer

mod_alias.c rule to redirect all subdirectories

A mod_alias newbie here. I found the rewrite rule below somewhere and have been using it to block bots and hackers that hit my site, looking for directories like HNAP1, wp, blog, etc. And it works for that, returning a Forbidden 403…
markratledge
  • 519
  • 5
  • 13
  • 26
0
votes
1 answer

Linking to items outside of the web root

Here is how the directories are laid out on my server (I inherited this and cannot change at the moment) - /var/www/ /home/project/src/static/ In the grand scheme of not wanting to have duplicate…
0
votes
1 answer

Redirect domain/directory to domain2/directory

I would like domain1.com/customers to go to domain2 my home directory public html's folder / customers. Both domains are on different servers. In the folder on the second server/second domain we will run several test sites for our clients.Sites like…
rhand
  • 264
  • 2
  • 5
  • 23
0
votes
1 answer

Using mod_headers to override mod_alias

I am trying to use mod_headers to change Location headers that are being sent via the mod_alias using the Redirect directive but none of them are being re-written. I have the following in my http.conf; Header edit Location //example.com…
nathanjosiah
  • 165
  • 3
  • 13
0
votes
2 answers

Create a case-insensitive apache alias

I am currently using Apache 2.4.4. Now, the problem is that when I am creating alias like Alias /mysite "D:/MySite" it doesn't work for http://127.0.0.1/MySite. So how can I make it case insensitive?
user170461
0
votes
1 answer

single page redirect 301 not working according to the rules in .htaccess

redirect 301 /Produkte/Supplements http://xxx.xx/Produkte/Inhaltsstoffe/Proteine why does this rule also redirects /Produkte/Supplements/xyz to http://xxx.xx/Produkte/Inhaltsstoffe/Proteine/xyz ? can't get my head around it.
kritop
  • 131
  • 1
  • 3
0
votes
2 answers

Apache 2.2 logging Redirects

How do I get Apache to log particular Redirects in a separate log file? I have a web site which includes links to an external site. I have been asked to keep track of how often users use these links. I can change them all to point to a redirector on…
Ricky Morse
  • 173
  • 1
  • 5
0
votes
3 answers

Apache URL rewrite for subdomain pointing to an existing virtual server resource?

I'm trying to point subdomain.example.com to a resource on subdomain2.example.com/?page_id=1 It's a wordpress blog. I'm attempting to give a static page its own subdomain. The point is to basically showcase the existing resource without giving away…
user57454
0
votes
1 answer

Apache AliasMatch with Wildcard Not Working As Intended

I am trying map all wildcards for a directory /a/* onto on file article.php using AliasMatch ^/a/(.*) /article.php but without redirecting (I want to keep the url looking the same). But I am getting a The requested URL was not found on this server.…
Maciek Semik
  • 139
  • 6