// Javascript (double-click function to any word on the page)
// Step 1. Add the following code in the head of all your pages:
// <script src="http://www.thefreedictionary.com/dict.js"></script>
// Step 2. Modify the body tag as follows:
// <body ondblclick="dictionary()">
// Double-click any word on your site they will get an instant definition. 

function dictionary() {
	if (navigator.appName!='Microsoft Internet Explorer') {
		var t = document.getSelection();
		od(t);
		}
	else {
		var t = document.selection.createRange();
		if(document.selection.type == 'Text' && t.text>'') {
			document.selection.empty();
			od(t.text);
			}
		}
	function od(t) {
		while (t.substr(t.length-1,1)==' ') 
		t=t.substr(0,t.length-1)
		while (t.substr(0,1)==' ') 
		t=t.substr(1)
		if (t) window.open('http://www2.thefreedictionary.com/'+escape(t), 'dict', 'width=700,height=500,resizable=1,menubar=0,scrollbars=1,status=0,titlebar=0,toolbar=0,location=0,personalbar=0');
		}   
	}
status='DOUBLE-CLICK ANY WORD - Get An INSTANT Dictionary Definition.'
document.ondblclick=dictionary //works for IE only. For NS add <body ondblclick="dictionary()">

function checkData()	{
	var correct = true
	if (document.Checker.text.value == "") {correct = false; alert("ENTER SOMETHING TO SEARCH FOR")}
	return correct
	}
