Directory-level configuration file found mostly on Apache web servers

learn more… | top users | synonyms (1)

1
vote
1answer
237 views

Cache Busting and Include Files for Nginx

In Apache you can use the following to cache bust css and js files and server them as a single file with Apache's Include mod: <FilesMatch "\.combined\.js$"> Options +Includes ...
0
votes
1answer
61 views

.htaccess - permissions forbidden

I have an error with a new virtual host that I can't figure out.. My .htaccess doesn't have web access (403). [Thu Oct 31 17:51:01 2013] [crit] [client ] (13)Permission denied: /srv/data_disk/www ...
0
votes
3answers
153 views

How do I redirect my website from non-www to WWW using Apache2? [closed]

I'm currently trying to set up my personal webpage. I am using a VPS and have manually installed Wordpress, and everything seems to work... except if I go to the non-www version of my website, it ...
5
votes
1answer
103 views

How to minimise effect of mischievous, persistent POST requests

For a few months now one of our shared hosting servers has been persistently and constantly hammered by "POST /" requests from what must be hundreds of thousands of individual IPs. On a number of ...
0
votes
1answer
91 views

.htaccess rewrite rule to ignore a directory

I am running a Symphony installation out of the directory symphony but I want to remove that word from the URL in specific cases. When a user visits http://domain.com/demo It should go to ...
-4
votes
1answer
188 views

How to change .htaccess file to work right in localhost? [closed]

I have this snippet code in my .htaccess file to prevent users from hotlinking the server's images: RewriteEngine On RewriteCond %{HTTP_REFERER} ^$ [OR] RewriteCond %{HTTP_REFERER} ...
0
votes
1answer
111 views

.htaccess redirect root directory and subpages with parameters

I am having difficulty trying to redirect a root directory while at the same time redirect pages in a sub directory to a different URL. For example: http://test.example.com/olddir/sub/page.php?v=one ...
1
vote
1answer
160 views

Add separate domain name to Wordpress admin area with htaccess

I have a Wordpress installation in a seperate folder on my server (meaning it is not in the root folder). Let's call that folder "folder A". I have a htaccess rewrite rule that maps Domain A to folder ...
0
votes
2answers
58 views

301 redirect from non www to www issue

I have been trying to set a 301 redirect from a non www to a www domain since yesterday but it only cause problems on my site. I first tried it from the control panel of the website, then by modifying ...
0
votes
1answer
79 views

Accessing Apache virtual host on my local machine

I use dyndsn.org and port forwarding to manage access of my local Apache webserver from the Internet. It access my apache htdocs via http://myusername.dyndns.org/somesite. However, I have set an ...
0
votes
3answers
911 views

htaccess filesMatch exclusion

I have the following directive in my htaccess <filesMatch "\.(gif|jpe?g|png|js|css|swf|php|ico|txt|pdf|xml|html?)$"> FileETag None <ifModule mod_headers.c> Header unset ...
0
votes
1answer
89 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 ...
0
votes
0answers
40 views

vhost httpdconf and htaccess not working as it should

I have been struggling for several days now with a mobile redirect and cant get it working. In my vhost I have created a subdomain folder (m) for the mobile version of the website In the root I have ...
0
votes
1answer
100 views

Nginx complete folder protection not working

I have installed nginx(1.4.3) with PHP-FPM(5.4.20). i want to protect my wordpress wp-admin folder. my nginx configuration file domain.conf: server { listen 80; server_name example.com; ...
0
votes
1answer
152 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
1answer
38 views

htaccess parameter to subdomain

I would like to redirect this http://www.domain.com/test.php?sub=subdomain&type=cars redirects to http://subdomain.domain.com/cars I already have mod_rewrite rules to do the opposite: ...
0
votes
0answers
413 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, ...
0
votes
1answer
174 views

Prevent server beeing flooded with requests

I'm hosting a Wordpress-blog on an Apache server (shared hosting). For some reasons I've been receiving like 100 requests per second to xmlrpc.php for a few days. The access.log looks like this: ... ...
1
vote
1answer
107 views

Enable FastCGI on Litespeed

How would I enable my Litespeed server to process .fcgi files using a FastCGI module? I tried setting the handler to fcgid-script already but that doesn't work. Syntax: AddHandler fcgid-script ...
1
vote
1answer
416 views

Nginx 404 error page php with params

In Opencart, 404 error is shown in this url: /index.php?route=error/not_found This page has a 404 custom page with the template of all the website. I´ve tried in Nginx with: error_page 404 = ...
0
votes
1answer
146 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
650 views

How to hide my website port number on website url [closed]

My website has implemented by using JAVA. So we have taken VPS and installed Tomcat then deployed My website is appearing like this whenever I click www.mysite.com in url ... it is appearing as ...
0
votes
0answers
62 views

htaccess Rewrite leading zero in url causing trouble

I have a database with a string column made up of four unique digits attached to each record. I know this isn't the best way to do this but I'm kind of stuck with it. I'm trying to rewrite urls from ...
0
votes
1answer
120 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 ...
1
vote
1answer
19 views

Rewrite Rule for modifying URL structure

I am trying to create a mod rewrite rule to correctly change an existing url structure that looks like this: Old: ...
0
votes
1answer
67 views

.htaccess rewrite not working on port other than 80

I have a simple .htaccess that redirect everything that's not a file or directory to index.php RewriteEngine on # if a directory or a file exists, use it directly RewriteCond %{REQUEST_FILENAME} !-f ...
1
vote
2answers
1k 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
204 views

Mod Rewrite appends Document root in rewrite rules

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} ...
-1
votes
1answer
53 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
0answers
23 views

Intelligently filtering bogus query strings

A vBulletin site I maintain is on the wrong end of a DoS attack which is inexplicably routing through CloudFlare unimpeded by their DoS protection. The requests look like this: 1 /?ZZZZCQG=XJXAUD ...
1
vote
1answer
429 views

Using htaccess in Apache to block query string input

I have been staring at this for a while not I can't fathom it, probably a wood for the trees scenario. I am attempting to use HTACCESS to block certain inputs to a web server, so I have added the ...
1
vote
2answers
4k views

nginx and owncloud, .htaccess security warning

I have a problem with nginx and owncloud. When i access the owncloud's login page i get this error: Your data directory and your files are probably accessible from the internet. The .htaccess ...
3
votes
2answers
4k views

Why is allow not allowed here in apache2

I've the following in my httpd.conf file: <Directory "/www"> Options Indexes FollowSymLinks AllowOverride AuthConfig FileInfo Options=Indexes,Limit Order allow,deny Allow from ...
1
vote
1answer
171 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 ...
-1
votes
1answer
158 views

http:// to https:// Redirection with page reload in Apache 2 (HD Web Hosting) [duplicate]

I'm trying to check to see if the address accessed is using a secure connection when accessing a certain page, or not. If not, I want to redirect the traffic to the proper https:// address. I have ...
1
vote
1answer
397 views

How multiple <Directory> sections work in Apache configuration (httpd.conf)?

For example, if my '/etc/apache2/httpd.conf' looks like this: <Directory /> AllowOverride None </Directory> <Directory /home> AllowOverride FileInfo </Directory> ...
0
votes
1answer
1k 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
277 views

Apache Alias subdomain/folder to folder above subdomain

What I want to do is to create an alias at http://subdomain.example.com/login that points to /usr/.....etc/htdocs/example/login so that anytime someone is redirected to ...
1
vote
1answer
565 views

Internet explorer cannot display the page, other browsers can, possibly htaccess / server error

After the migration of a high traffic site, from Redhat to Suse, Internet Explorer users (of at least IE 9) have, in some cases, troubles to view the frontpage (error message: "Internet explorer ...
0
votes
1answer
57 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
210 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
76 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
207 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
28 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
1answer
63 views

htaccess redirect querystring value

I need to redirect www.URL.it/directory_one/index.php?param_one=XXX&param_two=**YYY** to www.URL.it/newpage.php?param_three=**YYY** I tried all I found online but the only things that works ...
0
votes
1answer
63 views

How to force HTTP for some pages in HTTPS forced website with htaccess? [duplicate]

A part of my htaccess that redirects HTTP traffic to HTTPS looks like this: RewriteCond %{HTTP:X-Forwarded-Proto} !https RewriteRule ^.*$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] I need allow ...
0
votes
1answer
531 views

how to stop htaccess URL redirect loop [duplicate]

I am new to htaccess. so when i want to do a url redirect using htacces, i always get a redirect loop, and don't know how to fix it. I have been searching on the web but coundn't find a solution for ...
0
votes
1answer
118 views

Rewrite condition rule to see if there are variables after the slash

Here's what I'm looking to do: if http://acme.com/ has nothing after the slash rewrite to http://www.acme.com/ if http://www.acme.com/ has nothing after the slash do not rewrite if http://acme.com/ ...
0
votes
1answer
105 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 ...
0
votes
0answers
69 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 ...