Sitemap with Rails
I finally got around to generating a sitemap for this site. I used these instructions for creating sitemaps in rails. Very simple and straight forward instructions.
Unfortunately, the sitemap created isn’t valid according to google. The xml document created has <link> tags instead of <loc> tags which google webmaster requires.

I am guessing that these errors mean that my sitemap is useless to Google. Still looking for a solution and will post an update as soon as I find one.
Typo Tweaks
There are some annoying things about Typo that are relatively easy to fix. Here are two changes that I have made. Pointers to other posts or sites documenting Typo fixes would be appreciated.
Change pagination on Articles page
Find the contents_controller.rb file in typo/app/controller/admin. Change:per_page => 15 to :per_page => 35 or how ever many posts you want to see at a time.
Save As Draft
In order the save posts as drafts in Typo, you can change the published date to some date in the future. Instead of doing this manually everytime you want to create a draft, you can create a link that will automatically save whatever post you are working on with a publish date far in the future. The following Typo changes add a link that allows you to create a draft post. The draft post will be save with a publish date approximately one year from the current date.
- Make a copy of new.rhtml, name it draft.rhtml and change the action in the form tag from “new” to “draft”.
- Add the following code to typo/app/helpers/admin/base_helper.rb
def task_draft(title)
task(title, 'draft')
end
- Add the following code to typo/app/views/admin/content/list.rhtml:
<div id="draft" style="display:none;position:absolute;">
<%= render :partial => "admin/content/draft" %>
</div>
- Also on the list.rhtml page, make sure you add the link from the list page to the draft page, like this:
<%= task_draft('Draft') %>
- Replace the get_or_build_article method in typo/app/controllers/admin/content_controller.rb with the following code:
def get_or_build_article
@article = case params[:action]
when 'new'
art = this_blog.articles.build
art.allow_comments = this_blog.default_allow_comments
art.allow_pings = this_blog.default_allow_pings
art.published = true
art
when 'edit'
this_blog.articles.find(params[:id])
when 'draft'
art = this_blog.articles.build
art.allow_comments = this_blog.default_allow_comments
art.allow_pings = this_blog.default_allow_pings
art.published = true
t = Time.now + (365 * 24 * 60 * 60)
art.published_at = t
art
else
raise "Don't know how to get article for action: #{params[:action]}"
end
end
More to come; any requests?
Tweaks Elsewhere
- Subdirectories for Typo’s image folder: Now you have no excuse for having a messy image folder!
- Speed Up Typo on Dreamhost
Mephisto

I was looking for the instructions to upgrade to Typo 4.0 (for my other blog). And my search for “upgrade typo” resulted in a link to Mephisto, which I have been wanting to try. So, I installed Mephisto on my local machine. Here are my first impressions:
- I liked that when you log out of Mephisto you are sent straight to your blog instead of some weird “Where would you like to go?” page. I am guessing that you could change this in Typo fairly easily.
- I didn’t like that tags have to be separated with commas
- I was left wondering, “What was so wrong about Typo that would make you write something like Mephisto? I mean from a UI design perspective Mephisto isn’t that much better than Typo 4.0.”
- But I am sure the Mephisto people are working on new features as I type this. So, I am considering upgrading my other blog to Mephisto and keeping this one on Typo. But which one should I try to write plugins/additions for?
- Theme uploading and editing
- You can subscribe to your own Overview feed, which includes upcoming as well as already published posts
- Mephisto has sections rather than categories, which I think will help users think of ways of using Mephisto to manage sites that aren’t blogs
- A Save As Draft Option
- A Bucket to use as a temporary place to toss some assets while browsing in the asset manager
If you know of any cool Mephisto features that I haven’t listed here, please post them.

