/*

  Copyright 2009 LIONICS Internet- und Netzwerklösungen, L. Fellermayr.
  Alle Rechte vorbehalten. Unbefugte Nutzung bzw. Weitergabe wird rechtlich
  verfolgt.

*/

function resizeContent ()
{

  desiredHeight = document.body.clientHeight - 170;

  /* Maximalhoehe fuer content-right */

  if (desiredHeight > 600)
    desiredHeight = 600;

  desiredTopImprint = 125 + desiredHeight + 20;
  desiredTopRU = desiredHeight + 7;

  eval ('document.getElementById (\'content\').style.height = \'' + desiredHeight + 'px\';');

  /* IE6 tut sich mit "100%" schwer, daher resizen wir auch "content-right" */
  eval ('document.getElementById (\'content-right\').style.height = \'' + desiredHeight + 'px\';');

  eval ('document.getElementById (\'rm1\').style.height = \'' + desiredHeight + 'px\';');
  eval ('document.getElementById (\'rm3\').style.height = \'' + desiredHeight + 'px\';');

  eval ('document.getElementById (\'imprint\').style.top = \'' + desiredTopImprint + 'px\';');
  eval ('document.getElementById (\'ru1\').style.top = \'' + desiredTopRU + 'px\';');
  eval ('document.getElementById (\'ru2\').style.top = \'' + desiredTopRU + 'px\';');
  eval ('document.getElementById (\'ru3\').style.top = \'' + desiredTopRU + 'px\';');


} // resizeContent ()

function tb_goaway (target)
{

  self.parent.tb_remove ();
  self.parent.location.href = target;

} // tb_goaway ()


function leaveForeignFrames ()
{

  if (top.frames.length > 0)
    top.location.href = self.location;

} // leaveForeignFrames ()


/* showVideo () : shortcut function for easier access */

function showVideo (idart, width, height)
{
// foo = alert (width + " " + height);
  tbwidth = width - 20;
  tbheight = height + 84;

  queryStr = 'front_content.php?idart=' + idart + '&amp;vw=' + width + '&amp;vh=' + height + '&amp;TB_iframe&amp;modal=true&amp;height=' + tbheight + '&amp;width=' + tbwidth;

  tb_show(null, queryStr, false);

} // showVideo ()

function showBox (idart, width, height)
{

  width -= 30;
  height -= 11;

  queryStr = 'front_content.php?idart=' + idart + '&amp;TB_iframe&amp;modal=true&amp;height=' + height + '&amp;width=' + width;

  tb_show(null, queryStr, false);

} // showBox ()

