Directory-level configuration file found mostly on Apache web servers

learn more… | top users | synonyms (1)

1
vote
2answers
140 views

Apache2 mod_rewrite failing for non-existent sub directories [duplicate]

An even shorter version of my .htaccess file (Last RewriteCond wasn't there) use to work perfectly on my shared web hosting but I've moved to a VPS with Ubuntu 12 with it's stock Apache2 but it simply ...
0
votes
1answer
31 views

Authentication just for HTTPS Requests in Apache

I configure the authentication for my webspace via a .htaccess file (I have no control over the httpd.conf file). For a secure implementation I have an automatic redirection of HTTP to HTTPS via ...
0
votes
1answer
79 views

Rewrite not working in htaccess (apache2.2.22, windows server 2012)

I'm sure that my .htaccess file is being read by Apache as I tried to write in random stuff in it, eg: "sifnoweijf", and my page could no longer be displayed. but why the following rewrite doesn't ...
1
vote
2answers
278 views

Amazon EC2 .htaccess and 500 Error

I have an Amazon EC2 (amzn-ami-pv-2013.09.0.x86_64-ebs (ami-149f7863)) on which I installed Apache, PHP and MySQL. All works fine until I try to activate .htaccess. I change AllOverride All in ...
1
vote
0answers
98 views

How to rewrite using htaccess if the file exists in another folder?

We are trying to rewrite to another folder if the file does not exist in the document root, but does exist in the other folder. The other folder is in a completely different location, which is ...
-1
votes
1answer
40 views

How do I redirect al url request using htaccess when I already have rewrite rules?

I've tried everything but simply can't get this to work. This is the default Wordpress redirect code that sits in my htaccess file: <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / ...
0
votes
1answer
57 views

Need Corrected htaccess File

I'm attempting to use a wordpress plugin called WP Fast Cache which creates static html files from all your posts, pages and categories. It creates the following directory structure inside ...
0
votes
1answer
216 views

serving static file from cookieless domain: alternative cookieless directory

I'm trying to follow all the guidelines of "Google Page Speed​​". The directive "Minimize request overhead" requires static content (images, js, css, etc.) on a static server (ie cookieless): ...
1
vote
2answers
185 views

Virtual Host Configuration and mod_rewrite - Removing PHP Extension and Adding Forward Slash

On my production server, things are fine: PHP extension removal and trailing slash rules are in place in my .htaccess file. But locally, this isn't working (well, partially, anyway). I'm running ...
0
votes
1answer
255 views

Denying access to website via htaccess based on http header

I've been trying for ages to get this to work and I can't put my finger on it. What I'm trying to do is block access to a site from a number of countries, based on the CF-IPCountry header added by ...
0
votes
1answer
531 views

Compress with Gzip or Deflate my CSS & JS files [closed]

i ve a fashion website & using wordpress. I want to Compress or Gzip or Deflate my CSS & JS files. i have tried many codes with .htaccess to compress but not working. Would any body help me ...
1
vote
1answer
176 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
54 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
130 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
95 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
75 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
110 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
88 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
95 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
50 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
66 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
475 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
56 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
33 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
75 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
94 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
32 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
223 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
94 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: ... ...
0
votes
0answers
67 views

redirect in htaccess for wildcard htaccess with subfolder

This is my htaccess at present RewriteEngine On # -FrontPage- IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti* <Limit GET POST> order deny,allow deny from all allow from all ...
1
vote
0answers
71 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 ...
0
votes
0answers
32 views

All subdomains were redirect to maindomain

my fresh dedicated server (ubuntu) is currently destroying a website by generating duplicate content. The bind dns server redirects all - also not existing - subdomains to the maindomain. It could be ...
1
vote
0answers
182 views

Centos Redirect to Fully Qualified Domain Name [closed]

I'd like to have my domain.com go to www.domain.com. I am on centos 6.3 with mysql, apache 2.2 , php 5.4 installed. I tried editing my httpd.conf file, my etc/hosts file and the htaccess file. I ...
1
vote
1answer
256 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
94 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
255 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
51 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
89 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
17 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
60 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
570 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
2answers
117 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
40 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
19 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
362 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
3k 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 ...
0
votes
0answers
26 views

htaccess go up a folder, above web root

I've been looking around on the internet, but i couldn't find a good answer to this question. Since i'm very new to htaccess, i would like to know how you would solve this problem. On my site, a user ...
3
votes
2answers
1k 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
131 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
122 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 ...