$(document).ready(
  function()
  {
    /* focusEmpty Elemente
    -  bei focus Feld leeren, sofern noch der Standardwert enthalten ist
    --------------------------------------------------------------------- */
    aFocusEmpty = Array();
    
    $('input.focusEmpty').each(
      function()
      {
        aFocusEmpty[$(this).attr('name')] = $(this).val();
      }
    );
    
    
    $('input.focusEmpty').focus(
      function()
      {
        if ($(this).val() == aFocusEmpty[$(this).attr('name')]) {
          $(this).val('');
        }
        $(this).addClass('inFocus');
      }
    ).blur(
      function()
      {
        if ($(this).val() == '') {
          $(this).val(aFocusEmpty[$(this).attr('name')]);
        }
        $(this).removeClass('inFocus');
      }
    );
    
    sURL = window.location.href;
    $('a.recommendLink').attr('href', '/system/weiterempfehlen.php?sURL='+sURL).fancybox(
      {
        'type': 'iframe',
        'transitionIn'  :  'elastic',
        'transitionOut'  :  'elastic',
        'speedIn'    :  600, 
        'speedOut'    :  200,
        'width': 560,
        'height': 600
      }
    );
    
    $("a.fancybox").fancybox();
    
    $("a.fancybox-gallery").fancybox({
      'transitionIn'  :  'elastic',
      'transitionOut'  :  'elastic',
      'speedIn'    :  600, 
      'speedOut'    :  200, 
      'overlayShow'  :  false
    });
    
  }
);
