I would say why reinvent the wheel as there are several good examples of html editors that can be easily adopted by you to use with Geeklog.
There is FCKeditor, TinyMCE, htmlArea, RichText Editor,etc. In addition majority of them have been already incorporated into Geeklog. You can find instructions/how-to's in this very forum.
Geeklog Polish Support Team