11th June, 2008
F-List to OPML in 11 Easy Steps
Wednesday, 10:46 am in Geeking
You remember a little while ago how I talked about stalking people on LiveJournal via RSS? Well, it’s come to my attention that people might be interested in learning the find-replace fu by which I turn a friends list into an OPML file for import into something like Google Reader. The trick is actually pretty simple. Here’s how it works.
You Will Need
- A friends list. This can be found on the profile page of any LJ Server-based journal.
- UltraEdit. Strictly speaking you can do this with any text editor (see caveats below), but UltraEdit is what I’m going to be using.
Step #1
First off, go to the profile page containing the f-list you wish to copy. Select all the user names (you can do communities, too, but you’ll have to do them separately as the URI is different), and press Ctrl+C to copy them (Option+C on a Mac).
Step #2
Paste (Ctrl+V) your list into your text editor. You should be left with a comma separated list of usernames.
Step #3
This is where the magic happens. Open your text editor’s find-replace box (probably Ctrl+R). In the Find field put:
,
(That’s comma-space, incidentally, not just comma. Don’t forget the space or this whole thing won’t work!)
And in the Replace field put:
.livejournal.com/data/atom?auth=digest"/>^p <outline type="rss" xmlUrl="http://loqia:********@
Here’s where you get some options.
- Change
livejournal.comtojournalfen.net/insanejournal.com/whatever if appropriate (but see below). - Remove
?auth=digestif you don’t want to authorise yourself. This will mean you won’t be able to read your f-locked entries, but remember that a lot of feed readers – including Google Reader – don’t support this authentication method. - The
^pinserts a new line character in UltraEdit. Strictly speaking, you don’t need this; it just makes your file a bit neater. Remove it if you’re using something like Notepad, or replace it with whatever your editor uses as a new line replacement. If you’re unsure, remove it. loqia:********@is used in conjunction with?auth=digestabove. If you’ve removed that bit, remove this too. If you’re leaving it in, remember to changeloqiato your username and********to your account’s password.
Execute your find-replace across all comma-spaces in your file.
Step #4
If all is well, you should end up with something like this.
Step #5
Now, go to the very start of the very first line in your file. Insert the following:
<?xml version="1.0" encoding="UTF-8"?>
<opml version="1.0">
<head>
<title>My F-List</title>
</head>
<body>
<outline title="F-List" text="F-List">
<outline type="rss" xmlUrl="http://loqia:********@
(Remember to change loqia:********@ in the same way you did in the previous step.)
You can change the My F-List and F-List text if you really want to. This usually maps to the folder name your reader will import your feeds into. Remember: No quote marks.
Step #6
Check you’ve got something that looks like this (note I changed the title; inconsistent me).
Step #7
Now go to the very end of the very last line in your file. Insert the following:
.livejournal.com/data/atom?auth=digest"/>
</outline>
</body>
</opml>
(Again, remembering to change the server name and auth string if appropriate.)
Step #8
Review time again. Okay, this is a crappy example pic. Hopefully you get the idea.
Step #9
Save you file! Call it whatever you want, but make sure to give it the extension .xml. Congratulations, you just turned a CSV list into an OPML file! You 1337 data-manipulator, you.
Step #10
Import your shiny new OPML file into your RSS reader of choice. Each reader has a different way of doing this, so you’re on your own for this step.
Step #11
Profit!
Extension Homework
Incidentally, this process for doing communities is almost exactly the same. The only difference is the replace string looks like:
/data/atom?auth=digest"/>^p <outline type="rss" xmlUrl="http://loqia:********@community.livejournal.com/
I’ll let you figure out the changes to Step #5 and Step #7 yourself.
Oh, and for sites like JournalFen that don’t support usernames-as-subdomains, you’re looking at something more like:
/data/atom?auth=digest"/>^p <outline type="rss" xmlUrl="http://loqia:********@journalfen.net/
Again, I’m sure you’re clever enough to handle the other changes.
So, yeah. Easy.
- « Previous
- Next »
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.1.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.2.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.3.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.4.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.5.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.6.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.7.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.8.png)
![[ image ]](http://archive.void-star.net/sk.log/images/.lt/20080611_f-list.to.opml.step.9.png)
![[ image ]](http://archive.void-star.net/sk.log/images/20080611_f-list.to.opml.profit.png)