Initial framework for new messages feature.

Completed code to create a new thread.

Added validate.js, which can be used throughout application for form validation.