I\'m using PHP to send html emails. I\'ve tried to import css files inside the email, and it works fine.
Most email clients either disable email JavaScript entirely, or only allow a subset of it, due to security reasons. Web-based clients such as Gmail are likely to fall into the former category.
You can try embedding the script file itself directly into the email, but overall using JS in emails is a bad idea that's best avoided.
edit
Remember, email is a static content-delivery mechanism. As another commentator noted, if you want to send someone dynamic content, email them a link to your DHTML webpage.