Joomla to Mediawiki help

0

My programming skills are near nonexistent, so I need some serious help here.

I have some pages (about 150) in a Joomla install that I want to open up to collaborative editing. I figure the best way to do this is to put the content of those Joomla pages into a wiki. Since both are based on MySQL databases, I figure exporting, converting and importing is my best bet.

(I’m figuring I’ll do the export and import using CSV files and phpMyAdmin, because I know how to do that and learning the database commands seems more difficult than it’s worth here. Ditto for massive regexing, plus the fact that I don’t know all the tags that might be lurking in the content.)

Perl seems to have the best combination of capabilities, but the CSV import extension returns an array of hashes. I know that data types can nest somewhat in Perl, but I have no idea how to traverse the hashes in the array to get the two fields out of the Joomla database export. Concatenating the fields should be simple, and the HTML-to-Wiki conversion extension looks reasonably easy. But again, I don’t know to create the CSV to import into the Wiki database.

PHP has a function to read CSV a line at a time, making the variable much less complex, but I can’t find a converter from HTML to MediaWiki.

Python has been a bust so far as finding anything.

So, any direction? Things I have missed or not considered?

Tags: asked April 20, 2010

Leave a Reply

3 Answers

2

Not really an answer, but what the news Web world really needs is a commenting system that has all the reputation bells and whistles of the HacksHackers/Stack Overflow/Server Fault/Super User/Doctype systems.

It's awesomeness stems from that not only does it foster accountability, it's "sticky," i.e. it rewards/encourages return visits and responsible participation. (And that will save the news industry before the iPad does.) The more I play with it, the more I like it.

<Swipe at Microsoft>
It's certainly one of the more impressive things I've seen built with C#/ASP.NET/IIS
</Swipe at Microsoft>

And if someone builds a reputationally-deep commenting system with Django/Python, so much the better! : )

Leave a Reply

472
2

As a side note, if you're interested in Processing, I found the O'Reilly book "Visualizing Data" to be excellent. The book goes from 'hello world' level to actually building some of the visualizations on Ben Fry's site.

Make sure that you download the errata though, as there are a number of errors in the code as printed that could trip up a beginner.

  1. +1 (belated) This is the book Rich and I used for the practical aspects of the independent study. Was helpful for learning more about Processing specifically, as well as gaining exposure to visualizations and programming in a more general sense.

Leave a Reply

30
1

Despite "Python has been a bust," here's a possible Python-based approach:

Django makes it possible to point it at an existing, legacy database:

http://docs.djangoproject.com/en/dev/howto/legacy-databases/

Here's a real-world series on how the above works:

http://www.mechanicalgirl.com/view/working-django-admin-and-legacy-databases-part-1/
http://www.mechanicalgirl.com/view/working-django-admin-and-legacy-databases-part-2/
http://www.mechanicalgirl.com/view/working-django-admin-and-legacy-databases-part-3/

Once you've got a Django handle on your data, it's easy to pull it out in a variety of editable, serialized formats (xml, json, yaml):

http://docs.djangoproject.com/en/dev/ref/django-admin/#dumpdata-appname-appname-appname-model

So then, you'll be able to re-arrange your data to fit into something like this (pretty nifty) already-built Django wiki app (with revision and markup support). http://code.google.com/p/django-wikiapp/

Is it a lot? Sure as heck is, but if you intend for your project to be around, one of Python's (and by extension Django's) selling points is maintainability.

Other great resources for the journey are the Google group:

http://groups.google.com/group/django-users/

and the IRC channel:

irc://irc.freenode.net/

Also — and this is the important bit — now you'll have your data in a framework, as opposed to a more narrowly focused application such as Joomla or Mediawiki, so down the road when yet another bit of inspiration hits you, you'll be in a much better shape to build out your framework rather than jumping through hoops trying to bend an app into doing something for which is wasn't designed!

Leave a Reply

472
1

If you find processing useful but aren't so much into Java, give Nodebox a try. It's a similar thing, but it uses Python instead.

  1. My brief reading led me to believe that Nodebox relies on deep Mac technology like CoreAnimaton. I’m not clear whether this is absolutely required or not. I went googling for “nodebox django” and came up with squat. Seems like if it were possible, someone would have done it. So something like Processing.js might be a better choice for live web output… but then it wouldn’t be in Python :)

  2. Honestly, I haven’t played enough with either Nodebox or Processing to get to the point of deploying something. Most of my Django-powered visualizations rely on Google Charts or HTML/CSS/Javascript. But I have wondered about the same thing: Is there an easy/obvious way to plug in external Python libraries? I’m not sure.

  3. Chris – I spent an evening playing with Nodebox based on your recommendation. Really enjoyed it. My reluctance about continuing with it is that it seems Mac-dependent – as far as I can tell there would be no way to hook it cleanly into a Django project for instance, pulling live data with querysets and rendering them into the page with NodeBox. Is that correct or am I missing something?

Leave a Reply

785
0

Is the Joomla site still running? If so, perhaps scraping it might be better/easier than extracting from the db, depending on how simple the internal structure of Joomla is, I don't have experience with it personally. Or perhaps extract it directly from the db and then use a script to tidy?

I've used MediaWiki quite a lot in the past and I wouldn't ever try inserting anything directly in to the MediaWiki database. It's really quite complex with various dependencies and such.

Since it is only 150 articles, you could either script a http post to create new articles in the wiki, or just copy and paste, as no doubt they need editing/categorising along the way anyhow.

Leave a Reply

30
0

There are versioning plugins for Joomla now. Have you tried those?

ken
0

Leave a Reply

0

Your Answer

Please login to post questions.