Notes RichText to HTML: the Philosopher's stone
For my own blog template, I wanted to add the option of entering a blog post via the Notes Client using Rich Text. In the IBM blog template this is the only option. In BlogSphere, you have the choice: HTML or Rich Text. Unfortunately, none of the two have exactly what I'm looking for: IBM Blog does not render inline images correctly an BlogSphere does not convert the HTML into XHTML. So I decided to have a go at making a mix to get the best of both.
The IBM Blog template hall of shame
At first, I wanted to take the IBM Blog code as the basis, mainly because it uses a class instead of separate functions as BlogSphere does. But during testing, very odd things happened
- If you edit a blog post, and someone enters a comment on it at the same time, you get a replication conflict.
- When clicking on it in the Notes client, even worse things happened: my post simply vanished completely. Lost forever.
- I also discovered that even when logged in as an authenticated user, the Blog template did not recognize me, but above all: it did allow me to enter an anonymous comment.
- When using inline images in Notes RichText, their paths are not computed correctly, so you get broken links.
- Whatever I do, I cannot get the categories to work correctly. And I'm looking for documentation on the internet in vain.
- I tried the web admin interface: it simply does not work, and I have no clue why. Is it supposed to work, but have I got my settings wrong?
Conclusion: maybe advise the guys selecting our corporate blog solution to forget about the IBM blog altogether.
How about BlogSphere?
The conversion of RichText into HTML in BlogSphere is simply brilliant: tables, inline images, hyperlinks, even your own custom HTML are rendered perfectly. Except for the fact that it does not output valid XHTML at the moment. But since I was invited to join the BlogSphere development team, this will soon change :-))
Conclusion
Sorry, no code this time (again). I am fighting with Notes Rich Text for the moment, to combine the IBM Blog conversion code with that of BlogSphere in a standalone application to make it re-usable in all domino web development. It will take me far more time than I expected.
Comments
07/07/2007 23:18:17, Jan Schulz
If you put that up to openntf, you will be my hero!
10/07/2007 00:12:32, Sean Burgess
Michel - Sounds to me like you have some configuration issues, that's for sure. It is very important that the url information is filled in correctly in the configuration document or very bad things can happen. The one problem above that I would expect to happen might be the rep conflict, but since I've never seen it happen, I can't say for sure.
If you want to drop me an email, I can work with you to get it setup correctly so you can do a good test. And if I don't know the answer, I will get Steve Castledine involved and we will make it work.
To add a comment, log in or register as new user. It's free and safe.