/**
* opens 675x570 popup window
*/
function open_new_window( url, width, height, scroll, resize )
{
  if ( ! scroll ) {
    scroll = "no";
  }
  if ( ! resize ) {
    resize = "no";
  }

  windowOpts  = "toolbar=1,location=0,directories=0,status=1,menubar=0,scrollbars=";
  windowOpts += scroll + ",resizable=" + resize;
  windowOpts += ",width=" + width + ",height=" + height;

  window.open(url,"_blank", windowOpts );

}

function open_large_window(url) 
{
  open_new_window( url, 675, 570, "yes", "yes" );

//email = window.open(url,"_blank","toolbar=1,location=0,directories=0,status=1,menubar=0,scrollbars=yes,resizable=yes,width=675,height=570");

}
 
/**
* opens 375x384 popup window
*/
function open_small_window(url) 
{

  open_new_window( url, 375, 384, "no", "yes" );

//email = window.open(url,"_blank","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=no,resizable=yes,width=375,height=384");
}

/**
* opens a 510x500 popup window
*/
function open_quiz_window(url) 
{
  open_new_window( url, 510, 500, "yes", "yes" );

// email = window.open(url,"_blank","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=yes,width=510,height=500");
}  

// Functions for managing paging
//
function doSkip( skip, form_action )
{
  setSkip(skip);
  list_form = document.forms['list'];
  list_form.action = form_action;
  list_form.submit();
}
function setSkip (skip) 
{
  present_skip = document.forms['list'].list_skip;
  if (present_skip) {
    new_skip = parseInt(present_skip.value) + parseInt (skip);
    if ( new_skip < 0 ) {
      new_skip = 0;
    }
    present_skip.value = new_skip;
    return true;
  }
  return false;
}

