added markdown support and try fix problems