function SetFocus() {  
  if (document.forms.length > 0) {
	var field = document.forms[0];    
	for (i=0; i<field.length; i++) {      
	  if ( (field.elements[i].type != "radio") && (field.elements[i].type != "image") && (field.elements[i].type != "hidden") && (field.elements[i].type != "reset") && (field.elements[i].type != "submit") ) {        
	    document.forms[0].elements[i].focus();        
		if ( (field.elements[i].type == "text") || (field.elements[i].type == "password") ) document.forms[0].elements[i].select();        
		break;      
	  }    
	}  
  }
}


function rowOverEffect(object) {  
  if (object.className == 'dataTableRow') object.className = 'dataTableRowOver';
}


function rowOutEffect(object) {  
  if (object.className == 'dataTableRowOver') object.className = 'dataTableRow';
}

/***************************************************************
*  Copyright notice
*
*  (c) 2008 Alex Kellner <alexander.kellner@einpraegsam.net>
*  All rights reserved
*
*  This script is part of the TYPO3 project. The TYPO3 project is
*  free software; you can redistribute it and/or modify
*  it under the terms of the GNU General Public License as published by
*  the Free Software Foundation; either version 2 of the License, or
*  (at your option) any later version.
*
*  The GNU General Public License can be found at
*  http://www.gnu.org/copyleft/gpl.html.
*
*  This script is distributed in the hope that it will be useful,
*  but WITHOUT ANY WARRANTY; without even the implied warranty of
*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
*  GNU General Public License for more details.
*
*  This copyright notice MUST APPEAR in all copies of the script!
***************************************************************/


function wt_socialbookmarks_add2favourite(Text, URL) {

	if (window.sidebar) { // firefox
		window.sidebar.addPanel(Text, URL, "");
	}
	
	else if(window.opera && window.print) { // opera
		var elem = document.createElement('a');
		elem.setAttribute('href', URL);
		elem.setAttribute('title', Text);
		elem.setAttribute('rel', 'sidebar');
		elem.click();
	}
	
	else if(document.all) { // ie
		window.external.AddFavorite(URL, Text);
	}
}