$(document).ready(function(){

$('textarea.tinymce').tinymce({
	// Location of TinyMCE script
	script_url : 'include/js/tiny_mce/tiny_mce.js',

	// General options
	theme : "advanced",
	plugins : "pagebreak,save,advhr,advimage,advlink,iespell,inlinepopups,insertdatetime,preview,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,advlist",

	// Theme options
	theme_advanced_buttons1 : "formatselect,fontselect,fontsizeselect,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright",
	theme_advanced_buttons2 : "cut,copy,paste,pagebreak,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,cleanup,code,|,insertdate,inserttime,preview,|,print",
	theme_advanced_buttons3 : "",
	theme_advanced_buttons4 : "",
	theme_advanced_toolbar_location : "top",
	theme_advanced_toolbar_align : "left",
	theme_advanced_statusbar_location : "bottom",
	theme_advanced_resizing : false,

	// Example content CSS (should be your site CSS)
	content_css : "include/css/global.css",

	// Drop lists for link/image/media/template dialogs
	template_external_list_url : "include/js/tiny_mce/lists/template_list.js",
	external_link_list_url : "include/js/tiny_mce/lists/link_list.js",

	// Replace values for the template plugin
	template_replace_values : {
		username : "Some User",
		staffid : "991234"
	}
});

// Initialize validate plugin
$("#commentForm").validate({
	rules: {
		name: 'required',
		email: {
		  required: true,
		  email: true
		}
	}, // End rules
	messages: {
		name: "Please type in your name.",
		email: {
			required: "Please type in your e-mail.",
			email: "This is not a valid e-mail (ex. casper@jquery.com)"
		}
	} // End messages
}); // End validate()

}); // End ready()