//<![CDATA[

function openimage(image, title, width, height) {
  var params = 'scrollbars=yes,resizable=yes,dependent=yes';
  if (!width) width = 100;
  if (!height) height = 100;
  params = 'width='+width+',height='+height+','+params;
  var win = window.open('image.html?image_='+image+'&amp;title_='+title, 'image', params);
  win.focus();
  return false;
}

function opengallery(folder, photo) {
  var params = 'width=560,height=800,scrollbars=yes,resizable=yes,dependent=yes,menubar=yes,status=yes';
  var win = window.open('gallery.html?folder_='+folder+'&amp;photo_='+photo, 'gallery', params);
  win.focus();
  return false;
}

function openprint(id, title, base, page, query_string) {
  var params = 'width=760,height=800,scrollbars=yes,resizable=yes,dependent=yes,menubar=yes,status=yes';
  var win = window.open('/'+base+'/'+page+'/print.html?document_id_:int='+id+'&amp;title_='+title+'&amp;'+query_string, 'print', params);
  win.focus();
  return false;
}

function openpdf() {
  return true;
  var params = 'width=560,height=800,scrollbars=yes,resizable=yes,dependent=yes,menubar=yes,status=yes';
  var win = window.open('pdf.html', 'pdf', params);
  win.focus();
  return false;
}

function ticker(pos) {
  var max = 2 * (47 + 64 + 47 + 52)
  var step = 10;
  if (pos) {
    pos = pos + step;
  } else {
    pos = step;
  }
  if (pos > max) {
    pos = step;
  }
  $("#ticker").css('left', '-'+pos+'px');
  setTimeout('ticker('+pos+')', 1000);
}

$(document).ready(function(){

  $("#information").show(function(){
    ticker();
  });

});

//]]>
