Warrior Forum - The #1 Digital Marketing Forum & Marketplace

Warrior Forum - The #1 Digital Marketing Forum & Marketplace (https://www.warriorforum.com/)
-   Website Design (https://www.warriorforum.com/website-design/)
-   -   Permalink Structure (https://www.warriorforum.com/website-design/387540-permalink-structure.html)

keyconcepts 27th May 2011 09:58 AM

Permalink Structure
 
I want to change my permalink structure so that the postnames are in the link, not just a number id. I know how to change it within WP, but I do not know how to change the htaccess file to make it work.

Does anyone know if there is a plugin to make this work more easily? I thought by changing that setting before starting the blog it might work, but even then it wanted me to change the htaccess. And I have other sites with lots of pages and posts, so I need something to make this simple for me. :)

Thanks.

Istvan Horvath 27th May 2011 10:27 AM

Re: Permalink Structure
 
2 options:
- make your .htaccess file writable (chmod 666) and WP will take care of it - NOT recommended

- when WP says you need to update your .htaccess file it also gives you exactly the several lines you need to copy/paste into your htacces file. Edit the file and upload it via FTP to your root directory. Done.

haymanpl 27th May 2011 12:26 PM

Re: Permalink Structure
 
You don't need to change the htaccess file if you use the proper redirection plugin before you change to the custom permalink structure to /%category%/%postname%/

or /%postname%/

WordPress.org codex is not totally reliable and accurate.

keyconcepts 27th May 2011 12:44 PM

Re: Permalink Structure
 
Before getting haymanpl's reply, I tried to change the htaccess but could not find one. So I uploaded my own. At that point, the blog would not open at all. So I deleted it, and it came back, but still with the 404 because of the permalink change without the htaccess being updated. Where is the .htaccess file usually located?

Istvan Horvath 27th May 2011 12:57 PM

Re: Permalink Structure
 
Set your FTP to show "hidden files" and you will see it if it's there. It should be in the root directory, where all the WP files and directories are.
However, if you never worked before with the permalinks, maybe you don't have one.

This is all you need in that file:
Code:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

Remember, the file doesn't have a "name" just an extension:
.htaccess

keyconcepts 27th May 2011 01:12 PM

Re: Permalink Structure
 
Well here is what I did. I put what you have there in a text file and saved it as 1.htaccess.rtf. I then uploaded it into the root and changed the name to .htaccess

Is that correct?

When I do that I get an "internal server error" when I try to access the page.

I really appreciate your help.

Istvan Horvath 27th May 2011 01:31 PM

Re: Permalink Structure
 
That sounds right... except I never use any word processor for editing file. Use Notepad or any other plain text editor!

If it still doesn't work, it's time to ask your host whether they support mode_rewrite or not.

keyconcepts 27th May 2011 02:18 PM

Re: Permalink Structure
 
Ok. I used TextEdit on my Mac, but for some reason it saved as a rtf. Thanks.

clau82 27th May 2011 03:21 PM

Re: Permalink Structure
 
Quote:

Originally Posted by keyconcepts (Post 3964341)
Ok. I used TextEdit on my Mac, but for some reason it saved as a rtf. Thanks.

It's OK, upload the file and rename it once it's on the server


All times are GMT -6. The time now is 11:13 PM.