////////////////////////////////////////////////////////////////////
////  FILE : index.js
////  AUTHOR : Ben Clark
////  DATE : 4/11/2008
////  SITE : TNGhostHunters.com
////  USAGE RIGHTS : All rights are reserved and held by the
////                 Tennessee Ghost Hunters.  Usage of this script,
////                 elements of this script, and information
////                 contained within this document are strictly
////                 prohibited unless express written permission has
////                 been granted by Ben Clark or an authorized representative
////                 of the Tennessee Ghost Hunter group.
////  DESCRIPTION: This file contains general javascript functions used on 
////               the home page for TNGhostHunters.com.
////////////////////////////////////////////////////////////////////


//Define shorthand variables
var d = document;


function showHideElement(showHide_param, whichDiv_param) {
//This function shows and hides textual elements on the page. It is used to 
//make the page less overwhelming by hiding most of the text on the page
//unless the user desires to read it
//======> PARAMETERS
//  showHide_param : show | hide  - Show or Hide the text.
//  whichDiv_param : <NAME OF DIV ELEMENT> - This is the element which should
//                   be shown or hidden.

	var showHide = showHide_param;
	var which = whichDiv_param;
	var div = d.getElementById(which);  //The div object
	var str = ""; //String to return to div to be displayed
	
	if (which == "div_article2") {
		str += "<p>";
		str += "The state of Tennessee, especially Nashville and the Middle TN ";
		str += "area provides many location for the Tennessee Ghost Hunters to ";
		str += "research and conduct investigations into reported paranormal activity. ";
		str += "Looking back into history, there is no wonder that ghosts of Tennessee ";
		str += "span the entire state. We are here to offer our assistance and help to ";
		str += "those who believe they are experiencing ghosts or any paranormal ";
		str += "activity through confidential investigations and research.";  
		if (showHide == "show") {
			str += "</p>";
			str += "<p>It is our philosophy to try and rule out every natural explanation ";
			str += "for a haunting before considering the possibility of an active ";
			str += "haunting.  We practice this philosophy, not because we are non-believers, ";
			str += "but because we strive to provide authentic evidence of the paranormal.</p>";
			str += "<p>We do not make false claims about being experts but base our knowledge ";
			str += "of the paranormal on our experience gained through past and current ";
			str += "investigations.  We meet regularly and discuss current topics and share our ";
			str += "experiences and analyze evidence collected on assignments.  One of our goals ";
			str += "is to remain on the cutting edge in the field of paranormal research.</p>";
			str += "<p>Investigations we undertake are conducted in a scientific manner.  Using ";
			str += "the basic scientific method devised by Aristotle, being the repeating cycle ";
			str += "of observation, hypothesis, experimentation and verification, we use induction ";
			str += "to arrive at conclusions to our investigations. We emplasize site-based, ";
			str += "environmental data collection which we analyze determining any possible ";
			str += "cause which lead to the investigation being undertaken. Our investigations ";
			str += "are not elaborate productions and remain confidential unless we are given ";
			str += "explicit permission to share our findings.</p>";
			str += '<p>We do not conduct "exorcisms," nor do we engage in the termination of ';
			str += "paranormal activities. What you can expect is provide you our professional ";
			str += "attention, documentation of any evidence collected after analysis and assist ";
			str += "you in a resolution if one is sought.</p>";
			str += "<p>We, at Tennessee Ghost Hunters, feel people dealing with the paranormal ";
			str += "deserve a reliable source of information and support.  If you have come across ";
			str += "our website and happen to live in another state (not Tennessee), feel free to ";
			str += "contact us and we will provide you any help we may offer - including directing ";
			str += "you to a reliable and professional organization in your own area.<br />";
			str += '<a href="javascript:;" onClick="showHideElement(\'hide\',\'div_article2\');">';
			str += 'Hide Article...</a></p>';
		} else { //Hide it
			str += '<br /><a href="javascript:;" onClick="showHideElement(\'show\',\'div_article2\');">';
			str += 'Read More...</a></p>';
		}
	}
	
	//Write Results to Page
	div.innerHTML = str;
}