/* verify a link with a javascript dialog */
function verifyClick( message ) {
	if( typeof( message ) == 'string' ) {
		return confirm( message );
	} 

	return confirm( "Are you sure you want to delete this item?" );
}

/* create a popup with the provided link, window, width and height */
function sizedPopup( linkname, windowname, ww, wh ) {
	var href;

	if( !window.focus ) return true;

	if( typeof( linkname ) == 'string' ) { href = linkname; }
	else { href = linkname.href; }

	window.open( href, windowname, 'width='+ ww +', height= '+ wh +' ,scrollbars=no, resizable=no');

	return false;
}

/* image rollover code */
function changeImage( imageName, newImage ) {
	if( document.images ) {
		document[ imageName ].src = newImage;
	}
}

/* use css/dhtml to display or hide divs */
var currentTabId = 'imageTab';
function showTab( tabId ) {
        if( document.getElementById( tabId ) ) {
                if( document.getElementById( currentTabId ) ) { document.getElementById( currentTabId ).style.display = 'none'; }
                document.getElementById( tabId ).style.display = 'block';
                currentTabId = tabId;
        }
        return false;
}
