This project is read-only.

URL rewriting of imported posts

Oct 16, 2007 at 7:47 PM
Is there a way to get URL rewriting set up for the blogpost I import from dasblog?
My biggest concerns are that people link directly to my posts and as far as I can see, they will be broken if I make the switch to BlogEngine. There is both the permalinks and the /year/month/day/title links to rewrite.
Oct 16, 2007 at 8:40 PM
There is no direct mechanism for this, but the error404.aspx page is quite intelligent and will do a search of your posts to suggest to the visitor. If your old post with the /year/month/day/title format is referenced, then the 404 page will pick up on the title and suggest the closest match. It works very well. For permalinks GUID formatted links, it is much harder and a custom solution is needed. We are working on how to do this automatically from the BlogML import tool.
Oct 16, 2007 at 8:54 PM
ok. I guess it needs to have a simple url-to-url database that the error404.aspx page can use to look up in. All the import tool then need to do is to populate that database.
This would also benefit renaming of posts. If I rename a title, lets say because of a typo, the same database could be populated with the old and new name, and I don't have to worry about renaming blog posts.

Ellers skide godt arbejde Mads! Hold skruen i vand derhjemme i DK!
Oct 21, 2007 at 5:07 PM
Is there a way to setup a list of "301 perm redirect" links? To accomplish this task, I think I could setup 301 redirects from the DasBlog URL's to the new URL's -- Before I migrate, I want to ensure that my "perma-link's" stay perma!
Mar 31, 2008 at 1:58 PM
Has anyone built this "url rewriting" capability? A httpHandler for rewriting the URL pattern? SQL table linking? Something?

If not, maybe I can work on the importer application and build the linking application ...
Apr 19, 2008 at 3:05 PM
I accomplished this by adding a small routine to UrlRewrite.cs. I use a regex to figure out if the incoming URL is a 'DasBlog legacy format' url, and if it is, I response.Redirect to the equivalent BE.NET format URL. Kind of hacky, but at least my permalinks stay perma...