I have wordpress 2.7.1 and this is the time i thought of upgrading wordpress as i get
‘Declaration of … should be compatible with …’ errors. The existing wordpress url is like sitename.com/blog/. I want to install wordpress in a new section like sitename.com/blogtwo/ and want to do certain changes/tests as i had done some modifications in the existing blog. I wanted to make sure the new one works the same as the existing one so as to maintain SEO features. When it works fine i will rename blogtwo back to blog and find and replace the urls in the database. So, i created a new database and installed wordpress in sitename.com/blogtwo/ with the new database details.

Following are the steps i did.

  1. Extract wordpress into a new directory structure for example sitename.com/blogtwo/
  2. Created a new database ex new_db. Assume the existing db name as old_db.
  3. Installed wordpress by navigating to the url sitename.com/blogtwo/ and specified the new_db’s credentials. Installation was successful.
  4. I deleted the tables in the new_db. Imported the sql from old_db to new_db.
  5. I navigated to sitename.com/blogtwo/. It said you have to upgrade the database by showing an upgrade button. I did.
  6. I was able to login the admin section(i altered the users table to update username and password).
  7. In the admin section i could only see comments and categories. I could not see any posts. All i could see is a post with title ‘hello’.
  8. I navigated the main page of the blog sitename.com/blogtwo/. It was blank. View source was empty. No error log appeared.

Is there any other way to use the existing database in a new installation?
or any other method to upgrade an existing section/db to a new section of a site.


More InfoI have added this after following the first answer

Permalink is – Custom Structure: /%category%/%postname%/

htaccess is

RewriteEngine On
RewriteBase /codesnippets/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /codesnippets/index.php [L]
  1. I installed wordpress version 2.8 in php version 5.2.8 because in 5.4 i am getting Strict Standards: Declaration of Walker_Page::start_lvl() should be compatible with Walker::start_lvl(&$output)
  2. I dropped the tables and imported the existing one.
  3. Two fields were removed in 2.8. One is link_category and post_category in wp_links and wp_posts tables. I did the same in the imported tables.
  4. Logged in admin section and it showed all the information.
  5. But when i navigated the actual url sitename.com/blog/ the output is blank.

The above is the permalink and htaccess i had been using. So that my blog will show categories and posts of each categories. for example sitename.com/blog/http/ and sitename.com/blog/http/list-of-all-http-codes/

what would i be missing?

1 Answer
1

You should probably upgrade one step at a time from one version to the next. All the code of all the versions are listed at the http://wordpress.org site. It will be a long process but the best to ensure proper upgrades. You can try to make it faster by skipping several versions at each step, just always keep a backup before doing such skipping.

@ialocin points out there is actually a codex section for that http://codex.wordpress.org/Upgrading_WordPress_-_Extended_Instructions#Upgrading_Across_Multiple_Versions

Note: it is most likely that the minimal requirements for running wordpress had changed over that time. Make sure you are running a recent enough php version and have enough memory. It might be that your problems are related to php errors and not to the actual upgrade process.

Tags:

Leave a Reply

Your email address will not be published. Required fields are marked *