The most common name of the per-directory settings file for the Apache server. WordPress stores the mod_rewrite configuration for "Pretty Permalinks" here. [url-rewriting] should be used for the WordPress rewrite system in general, [mod-rewrite] when you talk specifically about the Apache module.

learn more… | top users | synonyms (1)

44
votes
7answers
6k views

Best collection of code for your .htaccess file [closed]

We have the Best Collection of Code for your functions.php file thread, so I thought that it might be useful to create a thread for our .htaccess files. AND PLEASE REMEMBER TO ADD ANY OF YOUR OWN ...
8
votes
3answers
4k views

Masking wp-content/themes/name/images to just images directory using htaccess

I'm trying what I thought would be something really simple of masking my url but cannot seem to get it to work. I want to be able to link to images in my img tag without having to type in the full ...
7
votes
7answers
13k views

Cannot access non-wordpress subdirectories as wordpress overrides them with a 404 error

I refer to this question previously asked and not suitably answered: Wordpress overriding actual subdirectories and also Non "Wordpress" pages/code getting 404 error. I have the same ...
7
votes
4answers
1k views

Security and .htaccess

About a month ago I started a WordPress blog on a hosted server related to a hobby. So, I am new to this at present. Since I'm concerned about security, one thing I did was to install the plugin WP ...
7
votes
5answers
4k views

How do I skip wordpress's 404 handling and redirect all 404 errors for static files to 404.html?

How do I skip wordpress's 404 handling and redirect all 404 errors for static files to 404.html? I read and it seems its not possible when using permalinks? The objective is to reduce the server ...
7
votes
1answer
2k views

Moving a WP Multisite to a subdirectory

Firstly, I've read a number of posts on this process. However, for various reasons, the process remains difficult to implement or troubleshoot for lack of even abstracted examples, or maybe too ...
6
votes
2answers
746 views

Multisite htaccess on localhost with WP as an SVN external?

I've mimicked Otto's setup here: http://ottopress.com/2011/creating-a-wordpress-site-using-svn/ and my brief example is below. That tutorial is specific to a single site install, and specifies a ...
5
votes
3answers
4k views

Setting up WordPress with Custom Permalinks and no .htaccess File?

I have a client that strongly prefers to disable .htaccess files because they like to set the Apache configurations themselves. However, they still want SEO-friendly URLs. Is there a way to have ...
5
votes
2answers
743 views

File and directory permissions

I installed latest WordPress 3.5 in my CentOS server. When I tried accessing http://example.com/wp-includes/, I received a listing of the directory: (Index of wp-includes). I added the following code ...
5
votes
1answer
263 views

Clash of the rewrites

I have a category called 'neighborhoods'. I also have child categories within 'neighborhoods' E.G. Lakewood, Highland Park... When I click 'highland park' the url is ...
4
votes
5answers
3k views

Use a different domain for SSL

long time lurker - first time poster. A client of mine has a website developed in CakePHP, and a wordpress blog installed in the /blog/ directory. Let's say the url of the main domain is ...
4
votes
2answers
615 views

How to change or remove .htaccess per plugin?

I am looking for a way to edit or reset the .htaccess for a wordpress site without access to the filesystem, working only with the wp-admin web interface and/or plugins* (see below for the back story ...
4
votes
2answers
214 views

What does a security risk in a plugin look like?

My server was hacked this weekend. By the Russians! Of the 50+ domains on my server, every single one had a hacked .htaccess file which was redirecting search results and a few other things to a ...
4
votes
2answers
161 views

Allow admin login at /admin

I am interested in: how can we change the default login url /wp-admin to /login how can we add another url for login so that both /wp-admin and /login would work I tried to use a custom filter and ...
4
votes
1answer
558 views

Redirect entire website to a single page

I need to redirect a whole WordPress site to a single WordPress page. A sort of maintenance mode, but the redirect has to go to a published WordPress page. Unfortunately, the maintenance page I need ...
4
votes
1answer
1k views

Passing variables through permalink structure

I have a WordPress page which is accessible via /accommodation/. What I want to be able to do is pass in a parameter using the URL - ie going to /accommodation/value1/ would load the same page as ...
3
votes
4answers
792 views

Plugin to edit htaccess file

Is there anyway I can edit my htaccess file without using ftp?
3
votes
1answer
2k views

Rewrite rules in .htaccess get overwritten?

I'm not able to make it work by adding custom rewrite rules into functions.php or adding custom permastructures either. I have this code in my .htaccess that is working fine. # BEGIN WordPress ...
3
votes
3answers
906 views

Options for restricting access to wp-admin

So i've installed a plug-in which allows me to enable two-factor authentication for my users. The problem is that to enable the plug-in i have to log in as that user and enable it via their profile ...
3
votes
1answer
116 views

Isolating WordPress to a subfolder

I'm trying to isolate a wordpress installation on our site to a specific subfolder. I created a folder on our root site named _wp and placed all the wordpress files in there. I added the following ...
3
votes
1answer
441 views

Add rewrite rule in plugin: with .htaccess in plugin folder or using WordPress functions

I need add a rewrite rule in my plugin, and distribute it with my code. All works fine if I put the rule in the .htaccess in the WordPress root folder, but I need distribute the plugin with my rule. ...
3
votes
1answer
161 views

Removing rules from .htaccess

I'm writing a small plugin that needs to write to .htaccess a simple non_wp_rule and i am doing it like this: function ci_flush_rules() { global $wp_rewrite; $wp_rewrite->flush_rules(); } ...
3
votes
1answer
411 views

301 Redirects for Changed Permalink Structure & Category Base

I'm redeveloping a site on a fresh WP install. The old site had the following permalink structure: domain.com/CATEGORY/POSTNAME/ The new site has the following permalink structure: ...
3
votes
2answers
625 views

W3 Total Cache Plugin with WP 3 MultiUser

I'm having some strange behavior with my W3 Total Cache solution working on my multi-user Wordpress 3 installation. The multi-user is setup to use sub directories, and I'm using all types of caching ...
3
votes
1answer
1k views

Wordpress multisite causing Error 101 (net::ERR_CONNECTION_RESET): Unknown error [duplicate]

Possible Duplicate: WordPress upgrade now receiving Error 101 (net::ERR_CONNECTION_RESET): Unknown error We have just installed WordPress 3.0.1 and everything worked fine. However, as soon ...
2
votes
2answers
1k views

Does WordPress Change the .htaccess File When Updating?

I've just implemented a new WP website, replacing an older hardcoded HTML site. I will be adding 301 redirects in the .htaccess file to point the old URIs to the new WP Permalinks. My questions is, ...
2
votes
4answers
486 views

Permalinks to Custom does not work (out of box)

I have tried to change mode of .htaccess in wordpress folder to 644. Yet, I get Not Found The requested URL /wordpress/features/ was not found on this server. I keep reading about rearranging my ...
2
votes
2answers
461 views

Why should I password protect WP-Admin?

Just occured to me: what's the point of password protecting www.yoursite.com/wp-admin when a user can just type www.yoursite.com/wp-login.php, bypassing the password on /wp-admin? Am I missing ...
2
votes
5answers
2k views

WordPress permalinks Yahoo hosting(no .htaccess allowed)

I have moved a Wordpress install to a client from sub folder to the root folder. Right now, everything works fine, except for the friendly URLs. I currently have to set the Permalink feature in ...
2
votes
2answers
590 views

Using WP rather than .htaccess to redirect pages/posts

I run a site with over 100 specific redirects in the htaccess for legacy html files that were subsequently brought into WP. There are also rules for pages within a date range to redirect to the home ...
2
votes
2answers
600 views

multisite htaccess 301 redirects

I've got a multisite sub-domain install with 3 sites on it. 2 of the sites use domain mapping. The main site (id=1) requires several 301's that are old pages from a previous structure such as: ...
2
votes
1answer
925 views

Two domains on one Wordpress Installation

I recently changed the base domain on my Wordpress website from http://www.fsdegrees.com to http://www.56degrees.co.uk. I would like to create various of 301 from old domain to new one, but for some ...
2
votes
4answers
1k views

Using only %postname%

So I see everyone's arguements against using this, but that seems like a huge flaw in Wordpress because a domain name as close to the root is crucial to a site's SEO. I want my site which has rough ...
2
votes
1answer
286 views

Blog.php or how to display recent posts?

I created a home.php which doesn't display the recent posts in the standard-blog-style. Just have a look at my website to see what I mean. I want to create a link that leads to something like ...
2
votes
1answer
567 views

Issue with using .htaccess to redirect feedburner feed

I am using year/month/post-name permalinks, and also using the download-monitor plugin to handle file downloads. I added rewrite rules to the top of the .htaccess file following the instructions at ...
2
votes
1answer
3k views

Wordpress .htaccess subdirectory problem

I've been having some issues with my Wordpress install allowing me to access subdirectories, specifically a CodeIgniter install at mydomain.com/codeigniter. I know that technically it should work just ...
2
votes
1answer
58 views

How to redirect url requests to https? [closed]

I've searched far and wide for a solution to this and I am sure it's simple but I simply couldn't find a solution. This is the regular wordpress redirect code: <IfModule mod_rewrite.c> ...
2
votes
1answer
182 views

Members area with externally-managed htaccess / htpasswd authentication?

I am looking at the feasibility of converting a client's site from countless hand-built web pages to a WordPress installation. The challenge is that we have a free area and a members-only area. The ...
2
votes
1answer
537 views

Htaccess redirect from '/%postname%.html' to '/%postname%'

I have a Drupal 5.x based travel review site which I'm moving over to Wordpress 3.x (same domain name). The Drupal site is structured like this: www.example.com/travel-guides (these are top-level ...
2
votes
1answer
723 views

How to rewrite WordPress uploads folder to another folder using htaccess

I found that the following code online could be used to spoof the WordPress uploads folder, rewriting URLs to a different folder on the server: # BEGIN Spoof wp-content/uploads directory ...
2
votes
1answer
1k views

Hijacking the URL for filtering

Right, here's the deal. I've got a loop of which displays news posts, these posts can belong to special categories (not normal categories) and I want to be able to filter by them. If I wasn't too ...
2
votes
1answer
892 views

Change of permalink structure - redirects in htaccess breaks the archive links

When I started with my blog, the permalinks and following structure: http://<domain>/%year%/%monthnum%/%day%/%postname%/ Some time ago, I changed the permalink structure to ...
2
votes
2answers
894 views

When WordPress Does Not Provide an .htaccess File for New Multisite Sites because of CPanel Fantastico Auto-Installer?

I have installed WordPress via an auto-installer and later configured it as multisite. But whenever I create the WordPress site using auto-installer it doesn't give me the .htaccess file by default. ...
2
votes
1answer
60 views

Multisite wordpress and subdomain URL collisions

I have a multisite WordPress installed on a server using a domain, site.com and I have a subdomain setup in WordPress, so subsites are at sub1.site.com, sub2.site.com etc. In addition to this, the ...
2
votes
2answers
1k views

How do I edit the htaccess file to optimize my website?

Hi I have tried to optimize my website energyshop.se for a cpl of days but I cant seem to get it done. This is how my .htaccess looks like: Header unset ETag FileETag None # Hantera och redirecta ...
2
votes
2answers
385 views

How to protect media directory with .htaccess?

I am trying to protect the uploads directory with .htacess. But when I browse media section in admin panel, I see user/pass popup. My guess is, WordPress use fopen to find if the file exists. I ...
2
votes
3answers
571 views

.htaccess and 500 error, extra character added

I am having a weird problem. Every few days I go to my website and get an "Internal Server Error" - Or 500 error. I go into the .htaccess file of the site and notice it's been altered. One character ...
2
votes
2answers
817 views

wordpress htaccess is hijacking my .mp4 files

I am running wordpress 3.2rc2 multisite. I inserted a few .mp4 videos into the root of my domain so that I can run a few basic tests with the jw player. When I try to access the url to the .mp4 ...
2
votes
2answers
6k views

How to change “wp-admin” to something else without search-replacing the core?

for example: foobar.com/wp/edit instead of foobar.com/wp/wp-admin How would I do that? I've tried using this in htaccess but it won't work: ##### ABOVE THIS POINT IS ALREADY INSERTED BY WORD PRESS ...
2
votes
2answers
1k views

WordPress upgrade now receiving Error 101 (net::ERR_CONNECTION_RESET): Unknown error

We have just updated to WordPress 3.1.3 by following the WP manual install tutorial. Note: This is a Network-enabled (multi-site) install. After uploading the new files, we now get the following error ...