made smartypants smarter

made the quoting replacements a bit smarter so that they handle apostrophes properly since i was noticing that they didn't. based off of [this post](http://www.leancrew.com/all-this/2010/11/smart-quotes-in-javascript/)