Anything, but not Everything angrys0ul

Netfirms Wordpress and Pretty URLs (Date and Name)

Update: Great news. The Wordpress pretty URLs problem has been fixed by the guys at Netfirms. One of the employees from Netfirms has posted a comment that they have fixed the issue and one of my friends who is on Netfirms confirmed it. Good job guys.

I have been with Netfirms for the past 7 months and i never had a problem with them, but last week i upgraded my Wordpress to 2.1.2 and now my blog is broken, any link on my blog brings me back to the homepage which is really frustating becasue even the comment link doenst work. I started searching for possible solutions when i found too many frustated Netfrims users complaining about the problem and many others suggesting fixes and then they reply back with no success.

The problem as some say is Netfrims has not enabled the Allow Override option for .htaccess rules to be considered so adding a /index.php before the Date and Name structure does the job, even the Netfirms support page says that you should use this

/index.php/%year%/%monthnum%/%day%/%postname%/

instead of the regular

/%year%/%monthnum%/%day%/%postname%/

for Date and Name permalink structure. So what you get won’t be exactly the date and name structure but with an extra index.php.

The problem with this is every post and every page and worse every category (every internal link to be exact) on your blog will have the index.php string added in the URL. It would be like http://mydomain.com/blog/index.php/about instead of the pretty http://mydomain.com/blog/about For me the situation was worse, Date and Name structure worked for me earlier but now it doesnt so all backlinks i got for individual posts now redirect to the homepage so the visitor doesnot see what he was expecting to see.

I went through a few Wordpress support topics, some of them very old to be considered as useful anymore. I even found a frustated Netfirms user who went as far as switching to another provider, ofcourse Permalinks was not the only reason for the switch but it was one of the main reasons. She really took off her anger by writing a lot about how bad netfrims was. That was just one persons case but most of us are having a good time with Netfrims arent we?

Now getting to what i have done to get my Date and Name permalinks back, i tried the workaround provided by Joel, who is another frustated Netfrims-Wordpress user. And the result is it didnt work. But i suggest you go try Joel’s workaround and the comments, he is really quick in giving you any kind of feedback if you tried his method to fix your permalinks.

I tried a part of what Joel did and it worked. Here is exactly what i did

Changed the permission for .htaccess file in my wordpress directory or the blog directory to 666 and then applied the Date and Name permalink structure through the Admin panel and then edited my .htaccess to this

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /blog/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !index.php
RewriteRule (.*) index.php/$1 [L]
</IfModule>

# END WordPress

where blog is the directory in which i installed wordpress and finally changed the permission of .htaccess file to 444.

Some more Wordpress specific rules i leant during this operation are

  • What ever may be the permalink structure you use, .htaccess content doenot change
  • Prepending /index.php to your structure should work irrespective of the contenets of .htaccess
  • Change your .htaccess after you apply a new permalink structure because when ever you choose a new structure, wordpress replaces the #WordPress section of the .htaccess file with the default content which is

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

  • Incase you edit the Wordpress part of the .htaccess file, you should lock it down with 444 permission so that wordpress doesnot replace it with the default contents. (Thanks Joel)

Now finally what exactly my settings look like

Permalink structure set to Date and Name

/%year%/%monthnum%/%day%/%postname%/

Contenets of .htaccess

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /blog/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !index.php
RewriteRule (.*) index.php/$1 [L]
</IfModule>

# END WordPress

PHP 4

Wordpress 2.1.2

.htaccess Enabled in NetFirms Control Panel


9 Comments

Yeah, I’ve had plenty of problems with Netfirms Wordpress too..although I was wonderingm is Netfirms now using version 2.1.2 or earlier?

Posted by Andy, Sqwink Design on 24 April 2007 @ 5am

Andy actually i upgraded my wordpress and you are right the one click install does not give you 2.1.2

you can see your version number at the bottom of any admin page, along with the execution time like this

2.1.2 — 1.46 seconds

Posted by angrys0ul on 24 April 2007 @ 9pm

Thank you! I was losing sleep during my efforts to resolve permalink problems on some of my sites, but this did the trick 100% and was straight to the point. Great post.

Posted by Dockwats on 31 May 2007 @ 12pm

[...] These days, I have little patience for problems that eat up time better spent with family or on work. Setting up this blog has been one problem after another. Setting up a blog should be as easy as filling out a form and pressing a button! Though I’m known to grumble under my breath, I’ll try to avoid carrying that habit into the on-line world. Netfirms (the hosting provider) has provided some good support. I also found this post by a fellow Netfirms customer helpful: http://angrys0ul.com/blog/2007/04/01/netfirms-wordpress-and-pretty-urls-date-and-name/ [...]

Posted by James Echmalian » Blog Woes on 15 September 2007 @ 6am

Dude had the same problem. Had to try something else for Wordpress 2.3 - some Canonical URL thing.

Anyways I put up a link to your blog post.

Posted by Harsha on 24 October 2007 @ 2pm

Thanks,
I did everything as you instructed, checked three time and this does not work at all. First it takes ages for page to load and than nothing happens!

Posted by Micho on 17 November 2007 @ 7pm

Although I still haven’t got my permanlinks looking (and working) exactly as I wish, I have to say this post is probably the best instructions i’ve found so far, and i have been looking a lot! Thanks.

Posted by Live Teen Blogger on 2 January 2008 @ 7am

[...] WP-Cache and Netfirms Terrible performance and technical support Netfirms Database Network Outage Netfirms Wordpress and Pretty URLs (Date and Name) Netfirms sucks Netfirms Loses Power, 1 Million Sites [...]

Posted by Registrar Transfer on 10 March 2008 @ 11pm

Wordpress Permalinks works out of the box as expected. A recent server upgrade made it all run fine.

Posted by TS on 29 March 2008 @ 7pm

Leave a Comment