The mod-rewrite tag has no wiki summary.
1
vote
1answer
181 views
mod_rewrite loop, redirecting http to https on certain section of wordpress blog
I'm trying to rewrite 3 sections of a wordpress site to https if they are accessed over http:
/cart/
/my-account/
/checkout/
As well as these rewrite's worpress has added a rewrite to remove ...
1
vote
1answer
1k views
“.#[random-char-string]” being inserted at end of URLs
I've seen this on a couple of sites now and I'm having trouble finding information about (probably because it's awkward to describe):
All internal URLs like this for example:
...
1
vote
1answer
73 views
Should I enable FastCGI on WordPress?
I am looking at my server settings and these are as follows:
WebDav : active
FastCGI : inactive
SSL support : active
Perl as Apache module : CGI-Programm
PHP module : ...
0
votes
1answer
47 views
Use the category name instead of category slug in permalinks
How to create a permalink structure which finish by:
/category-name/post-name/
Instead of:
/category-slug/post-name/
By default, Wordpress is offering %category% tag strucure as "A sanitized ...
0
votes
0answers
18 views
Add-on domain works in Wordpress but links still lead to subdomain
I know this looks like a common question, and I assure you I've tried a bunch of responses, but none seem to work in my case. I'm a Wordpress noob so I might be making some basic error which I can't ...
2
votes
1answer
111 views
Using custom post type parent as slug
I'm currently using the plugin 'Types Custom Post Type' to create custom post types (I know it's pretty easily done through functions.php but I was feeling a bit lazy!).
Basically, I'm looking to ...
0
votes
1answer
132 views
Redirect URL Containing åäö
I'm moving my blog from Typepad to Wordpress but have a big problem. Among the urls that are exported from Typepad, many containing åäö. When they are imported WordPress changes all URLs and instead ...
0
votes
1answer
39 views
Function to rewrite URl in Wordpress
I need to rewrte this URL http://example.com/news/?news_id=2 to http://example.com/news/2 where news is the page and 2 is the news_id
I have added following code in functions.php:
function ...
2
votes
2answers
254 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 ...
1
vote
0answers
57 views
Changing URL scheme, mod_rewrite not helping
We're trying to move away from the /YYYY/MM/DD/Post-Title URL structure without breaking links that are floating around on the internet. The mod_rewrite rule is fairly straight forward -
RewriteRule ...
2
votes
1answer
41 views
Change permalinks for posts but not for custom post types
Currently my permalink structure for posts is
domain.com/post-title
I'm using a static front page and a "blog" page for posts. I'd like to to change the permalink structure for posts, tags and ...
1
vote
1answer
340 views
Need help with simple rewrite rule (shouldn't this be easy?)
All I need is a rewrite that will change example.com/anyphrase into example.com.
Here is what I am using:
RewriteCond %{HTTP_HOST} ^example\.com
RewriteCond %{SCRIPT_FILENAME} !wp-admin
RewriteCond ...
0
votes
1answer
47 views
Custom domain for sub-section of parent website
While this topic could be considered a general web development item, I'm using WordPress, so I need to find some way to do this within WordPress and without breaking it. I realize this is a deep ...
2
votes
1answer
104 views
add new permalink structure from dynamic page
I created page "play" url: http://localhost/myweb/play and inside of page "play" I include PHP code to make the new search from outside Wordpress.
And all worked, if I search from my page "play" the ...
0
votes
1answer
204 views
Why wp redirects me to wp-login.php when I visit a rewritten wp-admin URL?
I have this rewrite rule
^dashboard(.*) wp-admin$1 [L]
and wp redirects me to wp-login.php when I try to visit /dashboard (even if I am logged in)
Any idea why this happen, and how I can solve ...
1
vote
2answers
116 views
mod_rewriting conflict with WP permalinks in htaccess [closed]
I need some help! I'm trying to rewrite this...
localhost/blog/?c=var to-> localhost/blog/var
But seems there is some problem... I get a 500 :( I also believe there is some conflict with the ...
0
votes
2answers
126 views
permalink results to “page not found”
Whenever I change my permalink option from the default to /%postname%/, it results into my page cannot be found.
Wordpress would complain that it cannot modify the .htaccess (because there was none), ...
1
vote
1answer
139 views
ReWriteRules and WordPress Multi-Sites with Sub Directories
I'm having a diffucult time getting the ReWriteRules and URL structures setup for a Wordpress 3.4.2 (latest version as of this post) blog with multi-site enabled.
www.ourdomain.com/ is the homepage ...
0
votes
2answers
347 views
Rewrite Rules Are Redirecting and Not Passing VARs
I have the following code in my functions.php file.
<?php
add_action('init', 'flush_rewrite_rules');
function custom_add_rewrite_rules( $wp_rewrite ) {
$new_rules = array(
...
3
votes
1answer
150 views
Sub domain redirection to taxonomy
Hi all I want to use sub domain for my taxonomy like that :
http://taxonomy.domain.com/apple map to http://www.domain.com/taxonomy/apple
I add this to my vhost
RewriteCond %{HTTP_HOST} ...
0
votes
1answer
33 views
Types plugin breaking because of server configuration
I have tested this on three different hosts, using a number of different versions of both Types and WordPress, and I believe I've narrowed it down to my host (Firehost) setup, which they recently ...
1
vote
2answers
71 views
a one-off rewrite rule
I have one page that I need to change the URL for.
Currently, the page resides at example.com/departments/human-resources/
(human-resources is a sub-page of /departments/ )
My client wants to ...
0
votes
2answers
101 views
How do I make WordPress revise an .htaccess file a certain way?
I've learned just a slight bit with WordPress Rewrite API -- just enough to add another rewrite rule for a plugin. The plugin works if installed in the root, but I'm finding that if one installs ...
3
votes
1answer
130 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();
}
...
1
vote
2answers
202 views
How to map permalinks with accented letters to sanitized slugs?
To keep legacy entries on a blog hosted on TypePad on sync with a new WordPress installation...
How do I map this permalink with accented letters:
domain.com/no-es-fácil-alejarse-de-la-política
to ...
0
votes
1answer
44 views
WordPress on a subfolder but accessible from root
I've searched quite a lot without finding a solution.
I have a wordpress blog in /_wp and something else in /other
What I'm trying to is that every request gets redirected to the WordPress. Except ...
1
vote
3answers
145 views
Wordpress home page showing 404 error
I've had a look for anyone experiencing the same issue but to no avail.
I am currently working on a Wordpress site that previously did not have permalinks, so have added these (i.e. to change the ...
1
vote
1answer
158 views
modrewrite not working on my Apache setup
Not sure if this is webmaster or a WordPress question, it's a bit half and half, sorry if I'm posting in the wrong place.
Without using Multi-Site or installing new WordPress CMS' in second-level ...
1
vote
1answer
253 views
WordPress mod_rewrite is canceling/overwriting my other mod_rewrite rule
in /www/ I have an .htaccess file containing:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^([^.]*\.less)$ compilers/lessphp.php?file=$1 [R,QSA,L]
...
0
votes
1answer
416 views
how to create several url aliases for a page
on the root page of a WordPress site we have a custom page template, that also handles some forms and dynamically changes part of the content.
Something like this:
<form action="" ...
1
vote
0answers
71 views
I have a page using a pretty url and a mod_rewrite rule matching it. I expected it to give an error but it's working. Why?
this may seem like a weird question but I have something working and I don't understand how.
I have moved my wordpress install to a subdirectory and am using the .htaccess file to redirect anything ...
1
vote
0answers
89 views
Some posts from custom post type to subdomains
I have custom post type where all posts associated with some persons.
Like: mysite.com/masters/master-name/
And i need to have redirection from master-name.mysite.com.
This redirection will be ...
1
vote
0answers
85 views
Evaluating a external rewrite rule before internal wordpress rewrite rule
I am been plucking out my hairs since last few days trying to solve this problem:
I want to convert my urls from format
http://example.com/prodsearch/category/tag1-tag2-tag3-tag4
to
...
4
votes
1answer
164 views
How to remove dates from existing permalinks?
After doing some research about dates on blogs, it seems like it is a good idea to remove them from the existing posts.
Consider:
Self-hosted (on Bluehost)
Over 1,000 existing posts
All posts are ...
2
votes
2answers
2k views
Making a plugin file accessible via url rewrite?
In my WordPress plugin I have a php file that generates some stats about the blog and outputs it as a simple text file. To access WordPress functions I've included this at the top of the file:
...
1
vote
1answer
782 views
Rewrite wp-login.php URLS to static pages?
I'm struggling with getting a few things in WP to redirect.
I'm using a front-end profile / profile editor, and I'm also using a front-end login/register.
Naturally I would like to redirect the ...
0
votes
2answers
136 views
How do I add my PHP app to a Wordpress page whilst keeping semantic URLs?
I am rebuilding a static website for a client using Wordpress on the main domain- eg domain.com. There is also a directory of members website at directory.domain.com which I was hoping to migrate over ...
0
votes
1answer
90 views
mod-rewrite rules grabs “broken permalinks”, too
This is the automatically generated htaccess file of WP using permalinks for the pattern /%year%/%postname%/ (working with http://localhost/BLOG-FOLDER/ yet):
<IfModule mod_rewrite.c>
...
1
vote
2answers
1k views
mod_rewrite enabled but Permalinks show index.php
I just installed a friends blog on my LAMP stack, which has mod_rewrite enabled (I'm using it for clean URLs on my Drupal installs on the same server). For some reason, WordPress (3.0.3) isn't ...
0
votes
1answer
792 views
404 error on all pages except home page [closed]
For no apparent reason, my wife's blog is only available on the homepage (i.e. the top domain). None of the posts or categories are available and I get a 404 error (a server 404 not a wordpress 404) ...
2
votes
2answers
1k views
Clean URLs for custom $_GET variables
I have a query var show=othertemplate that I can add to any URL to show any post, page or archive in Wordpress in a different template, like this: mysite.com/[any URL]/?show=othertemplate. I'd like ...
0
votes
2answers
218 views
modify URL with mod_rewrite or hook
i'm trying to achieve the following:
user enters this URL into browser
http://mydomain.com/boston/categoryname/postname/
i then want to get the first "folder" and check whether or not it's ...
0
votes
1answer
37 views
Need Help with Custom ModRewrite
How can I correctly send all traffic from:
http://my-domain.com/about/case-studies/clientName/
to
http://my-domain.com/about/case-studies/?clientName=$clientName
(not seen by visitors)
...
0
votes
1answer
82 views
How can I create a smarter .htaccess file that will add a directory?
This is my current .htaccess file:
Options +FollowSymLinks
RewriteEngine on
RewriteRule (.*) /directory/ [R=301,L]
And "directory" is where my wordpress install is. So this simply redirects people ...
6
votes
1answer
4k views
How to create custom URL routes?
I have a very peculiar requirement, hopefully I can explain it without being too confusing. I created a page template where I list some properties I get from an external XML file, so far no problems, ...
0
votes
1answer
149 views
How to configure Multisite Network with randomized hostnames?
I'm trying to convert a freshly-installed and functional WordPress into a multisite network. But I'm having problems because of our Apache configuration.
We use Apache to randomly redirect requests ...
0
votes
1answer
540 views
Rewrite rules for custom post type
There is a nonhierarchical custom post type "news".
/news/
/news/page/2/
/news/post_slug/
Each post has custom field "views". When someone opens post, field's value increased by one.
Would like ...
0
votes
1answer
311 views
why doesn't my rewrite rule work? (is there something weird with wordpress htaccess?)
My ht access includes:
Options +FollowSymLinks
RewriteEngine on
RewriteCond %{REQUEST_URI} ^/preview/(.*)\-[0-9]+$
RewriteRule ^/preview/(.*)\-[0-9]+$ /$1 [R=301,L]
but still when I try to access ...
0
votes
1answer
97 views
help with rewrite_tag and rewrite_rule for custom page GET variables [duplicate]
Possible Duplicate:
custom htaccess rewrite rule for page
ok i made another post and i got pointed to the Rewrite API
however, when i do print_r($_GET) on the page, it echos an empty array
...
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 ...
