10/17/2003 ↓

Blogroll import OPML bug in WordPress 0.72

Please subscribe to our RSS feed for new articles. We report on Wordpress news, themes, plugins, ideas, hacks, quick fixes and everything about blogging, especially about Wordpress. You can also receive updates from this blog via email if you want that method of notification.

I ran into some problems importing from BlogRolling OPML code into Wordpress 0.72. I took a very quick look and realized that the regular expressions dont match the OPML. I made some changes to Wordpress and I hope this helps someone.
Steps:
1) Look for links.import.php in the wp-admin folder.
2) Around line 108, replace the preg_match_all(’/ preg_match_all('//’,$opml,$items);

PS: Links in your BlogRoll which have never notified Blogrolling.com of updates will not transfer over with this script. (the way it stands now) My reg-ex knowledge is years old and I havent spent enough time fixing it. But basically, the “lastmod” item does not show up for those links that have never been updated and so those lines do not match the regular expression and gets left out. If I consider those to be optional through my expression, the code breaks because it keeps track of these items in an array which is dynamically generated.

1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 1 out of 5)
Loading ... Loading ...

Friends

Translate

Translate to German Translate to Spanish Translate to French Translate to Italian Translate to Portuguese Translate to Japanese Translate to Korean Translate to Russian Translate to Chinese

Latest Videos

Leave a comment

Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

(required)

(required, will not be published)


S2