/**
 * Project: starwoodmodels.com
 * Copyright 2008 Strictlyhelicopters
 * License GNU Public License V2.0
 * Sat May 03 CST 2008 15:28:18 ahelis
 * File: /includes/jscript/st.js
 *
 * General Javascript Object Literal.
	*
	* Note: this file is used by older and framework files that use
	*  the global function findDOM() and sd.findDOM() object literal. 
 */

/** st object
  *  @
  *  desc  Top level variable used for all modern functionality. 
*/
var st = {

oElement   : null,         // [object] object from 'this'
sLastId    : null,         // [string] last response id
sId        : null,         // [string] id attribute
isSD       : false,        // [boolean] true if sd object literal exists
sResColorAttr        : 'color',     // [string] response css attribute
sResActiveValue      : '#009900',   // [string] response highlight green
sResReadValue        : '#C0C0C0',   // [string] response highlight color 5EB85E,82D882,A0A0A0

/** function thisResponse(sId)
  *  @param sId  [string] response div id
  *  desc  Highlight the current response in the faq list.
*/
thisResponse : function(sId) {
		if (st.sLastId) st.thisRead();
		var obj = (st.isSD) ? sd.findDOM(sId,1) : findDOM(sId,1); // handle old and framework js files
		obj[st.sResColorAttr] = st.sResActiveValue;
  st.sLastId = sId;  // save current id to change to READ color
},

thisRead : function() {
		var obj = (st.isSD) ? sd.findDOM(st.sLastId,1) : findDOM(st.sLastId,1); // handle old and framework js files
		obj[st.sResColorAttr] = st.sResReadValue;
}

}

st.isSD = (typeof sd == 'undefined') ? false : true;