I recently discovered that I had additional paragraph (<p>) tags in my code and filters. It was screwing up my Word Gallery plugin because it was inserting paragraph tags into the javascript section. I found that it was actually the Shortcode Ultimate plugin that was doing it.
Luckily there is a setting to disable custom formatting if you are having trouble with other plugins. This also caused a problem earlier with the Contact Form 7 plugin.
source: http://wordpress.org/extend/plugins/ad-injection/faq/