http://pastebin.com/D88q76Xx