Ticket #3398 (reopened enhancement)

Opened 5 years ago

Last modified 4 months ago

import data from Geeklog

Reported by: justdave Owned by:
Priority: normal Milestone: WordPress.org
Component: Import Version:
Severity: critical Keywords: needs-patch needs-sample-data
Cc: garfiola, lingfish

Description

I recently converted my blog from geeklog to wordpress, and wound up converting the existing TextPattern importer to be able to pull data directly from a Geeklog database and import it to Wordpress.

The importer is incomplete, but usable, and currently imports categories, users, posts, and comments. It pretty much does what I needed it to do, and I'm sure someone else can make use of it, and possibly clean it up better.

Attachments

article.php Download (403 bytes) - added by justdave 5 years ago.
geeklog permalink redirects
geeklog.php Download (18.2 KB) - added by justdave 5 years ago.
geeklog importer

Change History

also worthy of note: I had to add these to my <VirtualHost> block in my apache config to make it work right:

php_value max_execution_time 300 php_value memory_limit 16M

Just add this to the script:

set_time_limit(300);
ini_set('memory_limit', '16M');

geeklog permalink redirects

geeklog importer

The new geeklog.php adds the time and memory limits to the code, and also inserts the story ID from geeklog into a _gl_sid key in the postmeta table. The story ID is then used by article.php to do lookups and redirect to wordpress' permalink when someone accesses the old geeklog-style permalink.

justdave is this tested against WordPress 2.0.x or 2.1 (beta)?

2.0.4 through 2.0.6

"PeterR" posted on my blog ( http://www.justdave.net/dave/2007/01/16/geeklog-to-wordpress-converter/) on May 12th:

"worked on geeklog 1.4.x and wordpress 2.1.3 for those interested."

  • Milestone set to 2.4 (future)

"Benjamin" posted today:

"For the record, I migrated a Geeklog 1.3.11 install to Wordpress 2.2.2 using your script. This was running on MySQL 4.1.20 and PHP 5.0.4 on a CentOS 4.5 system. Everything just worked!"

comment:9   matt4 years ago

Let's get this into core.

  • Milestone changed from 2.4 (future) to 2.3 (trunk)
  • Keywords has-patch added

justdave, do you have some sample import files? Could you attach it to the ticket?

(My guess is that these need to be updated to use the taxonomy system)

  • Milestone changed from 2.3 to 2.4

A little late to the game. Needs to be updated to use taxonomy.

comment:14 follow-up: ↓ 16   justdave4 years ago

I apparently missed the notification mail when the questions were asked of me back in September... I just happened to poke in here to check on it today. :)

I no longer have any of the old Geeklog stuff around (well, I might in a backup somewhere, I could go digging I suppose), so don't really have a way to test this anymore. It did it's job when I needed it. :)

What do you mean by "sample import files"? Do you mean like a mysqldump of a Geeklog database or something? OK, was just poking around, and I do have backups of the Geeklog setup from December 2006, including a dump of the database.

Was the TextPattern importer updated to use the taxonomy system? This thing was heavily based on that, so whatever was done to that could probably also be done to this to make it work.

This can be a plugin and distributed by wordpress extend plugin.

comment:16 in reply to: ↑ 14   lloydbudd4 years ago

  • Keywords needs-patch, needs-sample-data added; has-patch removed
  • Milestone changed from 2.5 to 2.6

Replying to darkdragon:

This can be a plugin and distributed by wordpress extend plugin.

Generally, I think the decision is to ship importers with WordPress to give the easiest experience getting started.

I've played with this more extensively today (I was the PeterR that reported on justdave's blog).

The import works with both wordpress 2.3.1 and 2.5.1 but the major problem I had was if there was a single quote (') in a post's title (Like Peter's new blog) it would screw up as the import script wasn't escaping them so you end up losing the post title (or part of it).

Also the import script doesn't handle single quotes well in the categories either (it actually leaves the escape chars in so "Peter's travel" became "Peter\'s travel". This one is a whole lot easier to fix though as you could just rename it after import.

I suspect these would be easily fixed by either a function that's used by other imports or copying the equivalent bit over from another import script.

  • Owner changed from anonymous to thee17
  • Status changed from new to assigned
  • Component changed from Administration to Import
  • Owner thee17 deleted
  • Status changed from assigned to new

hi,

i have programmed some additional features to this importer. it can be found at my blog:  http://tobid.wordpress.com/2008/11/16/geeklog-importer/

next to imports categories, users, posts, and comments it now imports links, static pages, and article images. further a list of posts which should be edited manually to remove all geeklog related tags is provided.

best regards,

tobias

  • Milestone changed from 2.9 to Future Release

comment:22 follow-up: ↓ 24   jacobsantos20 months ago

  • Keywords needs-patch, needs-sample-data removed
  • Status changed from new to closed
  • Resolution set to wontfix

Importers are all plugins now.

  • Milestone Future Release deleted

comment:24 in reply to: ↑ 22   westi19 months ago

  • Keywords needs-patch, needs-sample-data added
  • Status changed from closed to reopened
  • Resolution wontfix deleted
  • Milestone set to Future Release

Replying to jacobsantos:

Importers are all plugins now.

That doesn't mean that this is WONTFIX though.

We should have a supported Geeklog Importer in the .org repo and it integrated into the Importers page.

  • Cc garfiola added
  • Severity changed from normal to critical

this is not working at all, I could only import posts and they are all over the place...

It did not import users, categories, it onlyyy imported comments and posts.

But what can you do without

I am using latest wp 3.0 and geeklog 1.6.1

comment:26 follow-up: ↓ 27   garfiola15 months ago

can somebody fix this?

comment:27 in reply to: ↑ 26   westi15 months ago

Replying to garfiola:

can somebody fix this?

Does Geeklog have a usable export format or do we still need to do direct database queries?

No Geeklog does not export.

Are the urls of articles same??

Is it so hard to answer my posts, you just live people hanging here, there is no freaking info detailed one how to do import. You think everybody is an expert in wp

omg, this is not working at all. I think I will just manually import everything. SUch a shame

I cant even use WP 2.2 because php is version 5, can somebofy updates this page or not?????

I need help please you lazy bastards

Almost everyone here is volunteering their free time, so please be civil.

Last edited 13 months ago by scribu (previous) (diff)

Hi guys... I desperately want to migrate from Geeklog 1.6.0sr1 to the latest version of Wordpress. 3.03 or whatever is out now. Can someone help with this? Please reply here if you can help. It seems that this importer is for older versions? Any help or direction would be greatly appreciated!

Thanks, B

comment:34 follow-up: ↓ 36   lingfish4 months ago

  • Cc lingfish added
  • Keywords needs-patch added; needs-patch, removed

Hi, I'm too looking to move to WP from GL; had enough of it's terrible handling of custom themes when wanting to upgrade.

I see the status as needs-patch, needs-sample-data -- I'd like to help move this along and get support built right into WP, so how can I help?

  • Milestone changed from Future Release to WordPress.org

comment:36 in reply to: ↑ 34   dd324 months ago

Replying to lingfish:

I see the status as needs-patch, needs-sample-data -- I'd like to help move this along and get support built right into WP, so how can I help?

Since Geeklog doesn't have any export functionality, Any importer seemingly needs to be written with a decent knowledge of Geeklog, which rules many developers out at the outset. The best line of attack appears to be either

  1. Write a export module for Geeklog which exports to a WXR file
  2. Write a Importer Plugin for WordPress which reads the data directly from the MySQL Database.

Given the geeklog functionalities don't map directly to WordPress either, it makes it a bit more complex, Looking at  http://wiki.geeklog.net/index.php/DatabaseSchema there's a few things that can be imported:

  • Users
  • Stories (Posts)
  • Categories
  • Front-page (Sticky)
  • Comments
  • Pages

A few things that don't have a specific mapping:

  • Polls
  • Forum topics
  • Groups (User roles)
  • Events

As for the sample data that's required, A Example database and what all the metadata actually means would be useful.

Ok, noted. I'll start looking into this more, and agree that an export to WXR would be the ideal, rather than WP needing to deep-dive into evil Geeklog.

(BTW, strange -- I didn't get an e-mail notification of this ticket being updated, even though I've CC'd myself?)

(BTW, strange -- I didn't get an e-mail notification of this ticket being updated, even though I've CC'd myself?)

Make sure you have an email listed in your Trac profile

Note: See TracTickets for help on using tickets.