function check_spam_rating(url, rating, rejectRating) {
	
	if (rating == undefined ||  rating <= rejectRating ) {
		document.location.href = url;
	}
	else {
		alert( "This email cannot be selected for sending because it has a "+
			"spam rating of " + rejectRating + " or higher." );
	}
}

function el( id ) {
  if ( document.getElementById )
    return document.getElementById( id );
  else if ( window[id] )
    return window[id];
  return null;
}

function pel( id ) {
  if ( document.getElementById )
    return window.opener.document.getElementById( id );
  else if ( window.opener[id] )
    return window.opener[id];
  return null;
}

function show_el( id ) {
	el(id).style.display='';
}

function hide_el( id ) {
	el(id).style.display='none';
}

function del_conf() {
	return confirm( "Are you sure you want to delete this record?" );
}

function del_conf() {
	return confirm( "Are you sure you want to remove these records?" );
}

function add_conf() {
	return confirm( "Are you sure you want add this record?" );
}


function del_form( form ) {
	if ( !del_conf() )
		return false;
	else {
		form.actn.value='delete';
		return true;
	}
}

function del_link( mod , id ) {
	if ( del_conf() )
		location.href = 'index.php?module='+mod+'&actn=delete&id='+id;
}

function del_url( url ) { if ( del_conf() ) { location.href = url; } }

function rem_url( url ) { if ( rem_conf() ) { location.href = url; } }

function add_url( url ) { if ( add_conf() ) { location.href = url; } }

function clog(msg) {
var logger=0;
var browser=navigator.appName;

if (logger) {
	console.log(msg);
}
}