If you are interested in creating a simple single instance logger for an application, here is a simple logging example I created a few weeks back. The page includes a brief description and the code is commented.
I hope to be posting a lot more examples in the weeks to come. Often when writing about stuff, one does not get enough practice actually doing. So I am making a concerted effort to spend a lot more time practicing.