*
Welcome, Guest. Please login or register.
Did you miss your activation email?


HLEP:Changing my Permalink Structure?!
Pages: [1] 2   Go Down
  Print  

Author Topic: HLEP:Changing my Permalink Structure?!  (Read 2609 times)
0 Members and 1 Guest are viewing this topic.
Enblogopedia
Newbie
*

Karma: 0
Offline Offline

Posts: 35


View Profile WWW
« on: February 13, 2007, 18:25:59 PM »

Hi
I want to change my Permalink Structure from:
http://www.####com/2007/02/10/what-ever/

To:
http://www.####.com/what-ever/

I searched a lot about it and found the way
but I`m not sure from it!
I need to add this to the .htaccess:
Code:
RewriteEngine On
RewriteRule ^([0-9]{4})/([0-9]{2})/([0-9]{2})/(.+) http://www.enblogopedia.com/$1

Is this the right way?!
Note that, I`m doing this for SEO...
« Last Edit: February 28, 2007, 10:20:45 AM by Enblogopedia » Logged

Enblogopedia
Ajay
Administrator
Jr. Member
*****

Karma: 0
Offline Offline

Posts: 99



View Profile WWW
« Reply #1 on: February 13, 2007, 18:34:44 PM »

You might like to take a look at this plugin.

Do post the results.
Logged

Enblogopedia
Newbie
*

Karma: 0
Offline Offline

Posts: 35


View Profile WWW
« Reply #2 on: February 13, 2007, 19:00:39 PM »

Thanks ajay, it works!
I didn't wanted a plugin but why bother my self messing with the .htaccess file!

thanks again
Logged

Enblogopedia
Everton Blair
Get Paid To Surf
Administrator
Sr. Member
*****

Karma: 8
Offline Offline

Posts: 458



View Profile WWW
« Reply #3 on: February 13, 2007, 21:21:25 PM »

forget the plugin - do the following:

Code:
# BEGIN WordPress
<IfModule mod_rewrite.c>
Options +Indexes
Options +FollowSymlinks

RewriteEngine On
RewriteBase /

# Redirect Old Permalinks
RewriteRule ^enblogopedia.com/(.*)/(.*)/(.*)/(.*)$ http://www.enblogopedia.com/$4 [R=301,L]

# These are the standard WordPress Rules
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

Logged

Ajay
Administrator
Jr. Member
*****

Karma: 0
Offline Offline

Posts: 99



View Profile WWW
« Reply #4 on: February 14, 2007, 02:44:55 AM »

Everton's Solution above will also work well.
Logged

Enblogopedia
Newbie
*

Karma: 0
Offline Offline

Posts: 35


View Profile WWW
« Reply #5 on: February 28, 2007, 10:18:17 AM »

Oh...!!
I really should enable automatic notification!!!
I didn't see Everton`s post till now!!

Thanks..I`ll disable the plugin and use your method since the plugin has disadvantages especially with the old feed links!
Logged

Enblogopedia
Enblogopedia
Newbie
*

Karma: 0
Offline Offline

Posts: 35


View Profile WWW
« Reply #6 on: February 28, 2007, 11:05:00 AM »

Please Guys check this post and tell me, Should does Everton`s way solve the old feed links problem or I should use the rule I already have so my htaccess will be like:
Code:
# BEGIN WordPress
<IfModule mod_rewrite.c>
Options +Indexes
Options +FollowSymlinks

RewriteEngine On
RewriteBase /

# Redirect Old Permalinks
RewriteRule ^enblogopedia.com/(.*)/(.*)/(.*)/(.*)$ http://www.enblogopedia.com/$4 [R=301,L]
[color=red]# Redirect Old Feed Links
RewriteRule ^[0-9]{4}/[0-9]{2}/[0-9]{2}/([^/]+/feed/?.*) $1 [R=301,L][/color]

# These are the standard WordPress Rules
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

RewriteRule ^([0-9]{4}/[0-9]{2}/[0-9]{2}/.*/feed/) $1/feed/
</IfModule>

# END WordPress

Thank you!
Logged

Enblogopedia

Pages: [1] 2   Go Up
  Print  

 
Jump to:  


Powered by MySQL | Powered by PHP | Valid XHTML 1.0! | Valid CSS!
Page created in 0.171 seconds with 19 queries.