Tag Archives: wordpress

Fixing broken unicode in wordpress

I tried to use unicode stars in posts to show how much I liked some books. I was embarrassed to see them show up as ????? question marks. Yuck. Why is that happening?

I’ve been blogging for a long time and had a suspicion that it was going to be the age of this WordPress install. I’ve diligently upgraded the software, but nobody likes to migrate a DB schema. So I dug through the DB and sure enough, my wp-posts table is in latin1-ci. For non-nerds, that means it’s a case insensitive database that only is set to store “latin” characters – basic ABC123 and punctuation, but none of the fun unicode or non-latin characters in other languages.

I’ve done some digging and it looks like this isn’t a pushbutton process, so it looks like a weekend scripting adventure.

Orbital Reader is live

After a lot of subway rides and wednesday nights, you can now install the best feed reader for WordPress right from your wordpress admin panel.

Once you are logged into your wordpress admin screen:

  1. Click Plugins
  2. Click Add New
  3. Search the Codex for “Orbital”
  4. Install Plugin
  5. Activate Plugin

The plugin should show you where it is, tell you how to use it, and away you go!

THE WORLD IS yOURS

It’s early days on this thing, so please tell me what’s difficult, what’s wrong, what could be improved.

Unicode Icons in Orbital

Font icons are kind of fashionable in web development these days. What’s awesome about them is that you get all the clever wonderful benefits of how good browsers are at rendering webfonts. In a way, a web font used for font icons is like a png sprite for SVGs – you get one server round trip and then a bunch of reusable images.

It’s a good idea if you need to show some custom icons. Me, I’m too cheap for that. For Orbital I’m trying to make sure that there is a very small footprint. Rather than using a custom web font I’m just getting creative with the unicode tables.

Screen Shot 2013-08-06 at 5.40.43 PM

As far as I can tell, unicode has some pretty easy to understand symbols for add (+), refresh(⟳) and edit(✎). So I get decent, scalable icons for zero server round trips!

Wordprss is now Orbital Feed Reader

When I talked with Aaron about the name of the feed reader for WordPress I’m working on, he pointed out that it seems awfully close to the actual name WordPress. It also is impossible to say. I asked lots of folks for new name ideas, this is the one that stuck for me.

Orbital, because:

  • You can see a lot from orbit
  • I really like the band

  • It is easy to say and there isn’t a feed reader already named Orbital

In other news, I’m working with folks to install it on their servers and show them how to use it. Be my Alpha Tester, please!

How to export a data file from a WordPress plugin

As part of my hacking on WordPrss, I got to a point where I wanted to let folks import and export OPML files.
Exporting a file from a WordPress plugin doesn’t seem to be very well documented. I found an older article about it – here’s my take.

Provide a link to the file export

Export the data

This file isn’t getting included in through the normal wordpress mechanisms, so it has to do some more work than the rest of your plugin does. If you want to use the $wpdb or other handy wordpress items, you have to include those in.
I was about to hack up a way to include wp-config.php or wp-load.php when I ran across the simply named Don’t Include WP-Load, Please. He recommends a clever way to handle it all within wordpress, which I quite like. See below.

Now you can build out your export file – in this case export_opml.php – knowing that all of the WordPress utilities are there for you to use.

How to migrate your WordPress Blog between hosts.

My boss Mike needed to move his wine review blog from a friend’s hosting on lunarpages. I suggested he try dreamhost and he liked it – in a few minutes he had signed up for a free trial and used their 1-click install to set up a new install of wordpress.

Before he moved his domain to point from lunarpages to dreamhost I got him to prep by writing down a few important pieces of info. I’m trying to make sure I make this easier for other friends like I did when I helped Tove’s Thread For Thought move from WordPress.org to her own host.

Things to do before you change your domain to point to your new hosting

      Write down the name of your THEME. If you want to use the same theme, it’s important to write this down before you make the switch.
      Export your blog content from wordpress.
      Download your images. The wordpress export guide pretends this is easy, but it isn’t. If you are using the same domain name, I’m not sure what the easy way to do this is.

How to download your images

I wrote a python script that does this for you.
Make sure your system supports python. Next install BeautifulSoup – a great html parser for python.
Once that’s done, download this little script and change home and filesUrl to be your domain name.
Run the script, it should crawl your domain and download all of the images you host. Now follow the same steps of editing your export if needed and upload it all into your new blog at your new domain.

Hope that helps!

WordPrss – Subscribing to feeds is done

I’ve been plugging away at WordPrss on hacknights and subway rides and I have some progress to show for it.

I can show a feed, and shortcut keys help you navigate backwards and forwards through them. Clicking on a feed marks it as read. By default we hide read items, but you can always show them if you want.

You can manage the details of individual feeds – you can rename them etc.

Adding new feeds works and while I was at it I put in feed autodiscovery. Say you want to subscribe to a site but you just have the URL for the site.

Wordprss will do its best to figure out what feeds the site offers.

Choose one and away you go!

Now that this bit is done I’ll be working on getting the updating to work properly. Soon I’ll be ready to install it up on a server. Just got to sort through security and make sure the upgrade process is sorted…

WordpRSS Status Update: pretty sweet

Current image of wordprssI’ve been using my kaizen hack time to work on a social feed reader for WordPress. Right now, here’s what it can do:

  • Install itself and set up database tables
  • Put in a few sample feeds
  • Pull feed entries down into the database.
  • Display the list of feeds
  • When you select a feed, display the items

Continue reading WordpRSS Status Update: pretty sweet