<!--
// =======================================================================================
//    Photo database
//    Copyright of database format, engine and photos by redfish hypermedia
//
//    last updated: 220899 by Gerhard Wasner, gwasner@redfish.to
// =======================================================================================



topics  = new Array(); 
photos  = new Array(); 

function dw(s) {document.writeln(s);}

function regtopic (thedata) {
  topics[topics.length] = thedata
  return (topics.length - 1)
}

function regphoto (thedata) {
  photos[photos.length] = thedata
  return (photos.length - 1)
}


// ---------------------------------------------------------------------------------------
// --- define constructor: topic object 

function topic(dir,thumbsdir,title,description,date) 
{
  this.id=regtopic(this);
  this.dir=dir;
  this.thumbsdir=thumbsdir;
  this.title=title;
  this.description=description;
  this.date=date;
  this.photoidbegin=0;
  this.photoidend=0;
}

// ---------------------------------------------------------------------------------------
// --- define constructor: photo object 

function photo(topic,filename,title,imagetype,sizexl,sizeyl,sizexs,sizeys) 
{
  this.id=regphoto(this);
  this.topic=topic;
  this.filename=filename; 
  this.title=title;
  this.imagetype=imagetype; //i-ndividual, p-ersonas, n-aturaleza, c-ultura, a-nimales, b-uildings  
  this.sizexl=sizexl;
  this.sizeyl=sizeyl;
  this.sizexs=sizexs;
  this.sizeys=sizeys;
  //this.dateevent=dateevent;
  //this.datepublish=datepublish;
}

// -->

