add decode function
Merge branch 'gh-pages' of https://github.com/zhanhongtao/encode into gh-pages