Upgrading from 1.5.1.3 to 2.0.6
-
I was just wondering if anyone had some general tips for making the upgrade from 1.5.1.3 all the way to 2.0.6. I tried to do this a little while back to 2.0.5, but I couldn’t get permalinks working so I just kept using 1.5.1.3.
Is there an easy, idiot-proof way of doing this?
-
I upgraded a number of blogs from 1.5.3 to 2.0.5 without a problem, and without having to upgrade to intermediate versions of WordPress.
Just — as you would with anything else — make sure you back up both your database and your WordPress files first. Caution is a good practice. 🙂
hmmm, permalinks still aren’t working 🙁
… and what have you tried?
Me? I’d go to Options -> Permalinks and “reset” what I currently have to force an update to .htaccess (what WP needs there with 2.x is DRAMATICALLY reduced from 1.5x).
What do you mean by click reset? I see an “Update Permalink Structure” button, but clicking this didn’t help. I also followed the instructions on this (http://wordpress.org/support/topic/53442?replies=2) topic from what moshu suggested, but when i tried to enter the permalinks menu in the wordpress dashboard i just get this:
Fatal error: Call to undefined method WP_Rewrite::flush_rules() in /var/www/localhost/htdocs/wordpress/wp-admin/options-permalink.php on line 91
In addition, my old .htaccess file looked something like:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ – [S=60]
RewriteRule ^(about-me)/trackback/?$ /index.php?pagename=$1&tb=1 [QSA,L]
RewriteRule ^(about-me)/feed/(feed|rdf|rss|rss2|atom)/?$ /index.php?pagename=$1&feed=$2 [QSA,L]
RewriteRule ^(about-me)/(feed|rdf|rss|rss2|atom)/?$ /index.php?pagename=$1&feed=$2 [QSA,L]
RewriteRule ^(about-me)/page/?([0-9]{1,})/?$ /index.php?pagename=$1&paged=$2 [QSA,L]
RewriteRule ^(about-me)(/[0-9]+)?/?$ /index.php?pagename=$1&page=$2 [QSA,L]
RewriteRule ^(projects)/trackback/?$ /index.php?pagename=$1&tb=1 [QSA,L]
RewriteRule ^(projects)/feed/(feed|rdf|rss|rss2|atom)/?$ /index.php?pagename=$1&feed=$2 [QSA,L]
RewriteRule ^(projects)/(feed|rdf|rss|rss2|atom)/?$ /index.php?pagename=$1&feed=$2 [QSA,L]
RewriteRule ^(projects)/page/?([0-9]{1,})/?$ /index.php?pagename=$1&paged=$2 [QSA,L]
RewriteRule ^(projects)(/[0-9]+)?/?$ /index.php?pagename=$1&page=$2 [QSA,L]
…Whereas my new file is just this:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule># END WordPress
Hm. I’m not sure what version of WordPress you’re using.
Per moshu’s instructions, did you upload a WP file … and from the correct version?
DianeV, thanks for taking the time to try and help me out. I’m using WordPress version 2.0.6. I don’t know what you mean by “did you upload a WP file… and from the correct version”.
To summarize, I have two computers, the old one with wordpress 1.5.1.3 installed, and the new one with 2.0.6 installed.
I first copied my wordpress folder from the old computer to the new one, then installed wordpress 2.0.6 on the new computer over top of the copied directory structure. Then I got a wordpress database dump from the old machine, and imported it into mysql on the new machine. I upgraded the database on the new machine (per the automated process in /wordpress/wp-admin), and finally tried updating my permalink structure to no avail.
Lastly I tried copying classes.php and functions-post.php from the link moshu posted, but they broke my permalinks page inside my wordpress dashboard as I mentioned above.
“Fatal error: Call to undefined method WP_Rewrite::flush_rules()”
you havent uploaded all the files for the new version. thats defined inside /wp-includes/classes.php
its part of 2.0.x and wont be found in a 1.5.x install
>> I first copied my wordpress folder from the old computer to the new one, then installed wordpress 2.0.6 on the new computer over top of the copied directory structure. … (blah blah I couldnt follow the instructions)
The upgrade instructions were specific and said to delete the old files not to copy them over.
The logic for that is demonstrated here.. certain ftp clients wont overwrite remote files that are larger in size, etc.. there are several diff checks that an ftp client can make.
Deleting the files makes sure that new files are correctly uploaded under all circumstances, using any ftp client. (Theoretically)
>>I was just wondering if anyone had some general tips for making the upgrade from 1.5.1.3 all the way to 2.0.6.
Following the instructions is the first place to start. I upgraded a 1.5.x blog last night with my own custom theme, and lots of little hand-coded tricks that ive done, and had none of the more prevelant problems seen on these forums. No blank pages. No capabilities.php errors. No missing files. No login issues. No mysql connect errors.
The ONLY problems I had were related to a specific plugin, and some trackback/permalink issues. All of which I successfully troubleshooted and fixed last evening.
alright, i’m going to delete the entire wordpress folder from the new server for good measure, then try again, copying over old themes etc one by one.
ok, I deleted the wordpress folder, dropped my wordpress database, reinstalled wordpress 2.0.6, created and imported my wordpress database backup, upgraded the wordpress database via /wordpress/wp-admin, then went to options -> permalinks, and now i still get the error:
Fatal error: Call to undefined method WP_Rewrite::flush_rules() in /var/www/localhost/htdocs/wordpress/wp-admin/options-permalink.php on line 91
So it is not possible that this is caused by a plugin or an out of date file now is it?
I don’t know what to do now :/
EDIT: whoami, which upgrade instructions are you talking about?
Ok, I’ve discovered something. It appears that links like:
mikecookonline.com/projects don’t work, but if I change it to:
mikecookonline.com/index.php/projects it will work fine. How do I make the leap to getting it to work without that index.php in there?This may be a stupid question, but are you hand-coding those links in?
The setting for removing the index.php from URLs is in Options > Permalinks.
However, note that if you change the setting from what you had before, existing links from outside of your blog to your now-changed URLs will break, and you’ll have to account for that if it matters to you.
Sorry I haven’t responded in a while, i got frustrated and gave up for a bit.
What I meant was, if I type this address into my browser, it works fine: http://www.mikecookonline.com/index.php/projects
If I type this address into my browser, I get a 404: http://www.mikecookonline.com/projects
Likewise, http://www.mikecookonline.com/2006/12/26/microsoft-and-holiday-software-releases/ doesn’t work, but http://www.mikecookonline.com/index.php/2006/12/26/microsoft-and-holiday-software-releases/ does.
I didn’t see an option for removing the index.php from URLs in Options > Permalinks, but I have permalinks set to “Date and name based.”
Is there anything else I can try?
The topic ‘Upgrading from 1.5.1.3 to 2.0.6’ is closed to new replies.