/*****************************************************************************************************************
Filename = hhs59web.js
Copyright, 2008, Woodland Engineering

Revised 16-Nov-2008 Ken Curtis
*****************************************************************************************************************/

/*****************************************************************************************************************
This function causes browser to scroll to the top of the page.
*****************************************************************************************************************/
function HHS59GotoTop()
{

self.scrollTo(0,0);

} // end HHS59GotoTop()


/*****************************************************************************************************************
This function shows a photo of the individual's photo. It calls the overlib library function.

Note: Must include this style whereever overlib is used for photos
#overDiv
{
  height:           96px;
  width:            68px;
  background-color: transparent;
  background-repeat: no-repeat;
}
*****************************************************************************************************************/
function HHS59ShowPhoto
  (
  individualPhotoRefStr // Location of individual's photo image file.
  )
{

var photoRefStr = "../individuals/" + individualPhotoRefStr;

overlib('',BACKGROUND,photoRefStr,FGCOLOR,'',ABOVE);

} // end HHS59ShowPhoto()


// /*****************************************************************************************************************
// This function shows a photo of the individual's photo. It calls the overlib library function.
//
// Note: Must include this style whereever overlib is used for photos
// #overDiv
// {
//   height:           240px;
//   background-color: transparent;
//   background-repeat: no-repeat;
// }
// *****************************************************************************************************************/
// function CdCCShowPhoto
//   (
//   individualPhotoRefStr // Location of individual's photo image file.
//   )
// {
//
// var photoRefStr = "../individuals/" + individualPhotoRefStr;
//
// overlib('',BACKGROUND,photoRefStr,FGCOLOR,'',ABOVE);
//
// }; // end CdCCShowPhoto()


/*****************************************************************************************************************
This function displays the reunion form.
*****************************************************************************************************************/
function HHS59ShowReunionForm()
{

var ReunionFormWind = window.open("reunion_form.htm", "reunionform",
                            "width=740,height=640,resizable=1,menubar=1,scrollbars=1,location=0,directories=0");

// Blur this window and give focus to the new window (Doesn't seem to work for Opera.)
blur();
ReunionFormWind.focus();

} // end HHS59ShowReunionForm()


/*****************************************************************************************************************
This function displays the reunion form.
*****************************************************************************************************************/
function HHS59ShowVillagesForm()
{

var ReunionFormWind = window.open("villages_reunion_form.htm", "villagesreunionform",
                            "width=800,height=740,resizable=1,menubar=1,scrollbars=1,location=0,directories=0");

// Blur this window and give focus to the new window (Doesn't seem to work for Opera.)
blur();
ReunionFormWind.focus();

} // end HHS59ShowVillagesForm()


/*****************************************************************************************************************
This function displays the roommates list.
*****************************************************************************************************************/
function HHS59RoommateList()
{

var RoommateWind = window.open("roommates.htm", "roommate",
                            "width=740,height=640,resizable=1,menubar=1,scrollbars=1,location=0,directories=0");

// Blur this window and give focus to the new window (Doesn't seem to work for Opera.)
blur();
RoommateWind.focus();

} // end HHS59RoommateList()


/*****************************************************************************************************************
This function displays the roommates list.
*****************************************************************************************************************/
function HHS59HomeHostList()
{

var HomeHostWind = window.open("house_guest.htm","_self");

} // end HHS59HomeHostList()


/*****************************************************************************************************************
This function
*****************************************************************************************************************/
function HHS59SubmitComment()
{

var textAreaElem = document.getElementById("userscmnt");
var cmntStr = new String(textAreaElem.value);

var modifiedStr = new String(cmntStr.replace(/\n/g, "<br/>"));

textAreaElem.value = modifiedStr;

} // end HHS59SubmitComment()


