var aktiv;
var info = new Array();
info['Softcoverblock'] = new Object();
info['Spiralblock'] = new Object();
info['Terminator'] = new Object();



info['Softcoverblock'].text = '<p>Ein Block wie ein Buch, ganz sch&ouml;n clever, Seiten zum Beschriften und Heraustrennen.</p><p> Der Name steht auf dem Umschlag, der Umschlag ist mit unserem poppigen und peppigen "DATADRUCK-Gr&uuml;n" bedruckt.</p><p> Diese Farbe hat in allen Umfragen die meisten Zustimmungen erhalten, gut so, schaut sch&ouml;n aus.</p>';

info['Spiralblock'].text = '<p>Ein Block, praktischer geht es kaum. Die Metall-Spiralbindung ist eine Wucht, praktisch zum Bl&auml;ttern und auf Tischen mit wenig Platz ist dieser Block die Wahl der Stunde.</p><p> Der Umschlag ist gr&uuml;n "metallic" ein echt tolles Material und wird mit dem Namen Ihrer Wahl bedruckt.</p>';


info['Terminator'].text = '<p>H&ouml;rt sich gef&auml;hrlich an, ist aber "nur" m&auml;chtig praktisch.</p><p> Mit diesem Terminblock auf dem der eigene Name steht, machen Sie eine gute Figur, und das von Ihrem Wunschmonat ab, ein ganzes Jahr lang.</p><p> Ja, das ist der Digitaldruck.</p><p> Der Umschlag ist wieder in einem wundersch&ouml;nen gr&uuml;n gehalten, darauf steht Ihr (Wunsch)Name.</p>';




 $(document).ready(function() {

 /**
    * Infobox für die Weihnachtsbestellung
    */
	
 $('img.infoText').mouseover(function(){
  if(!document.getElementById('whb'))
  {
   var name = $(this).attr('alt');
   var text = info[name].text;
   var pos = $(this).offset();
   
   var box = '<div id="whb" style="left:'+(pos.left - 14)+'px;top:'+(pos.top - 3)+'px;"><div class="whbc"><div class="whbch"><h3>Information<br />'+name+'</h3></div><div class="whbct">'+text+'</div></div></div>';
   $('body').append(box);
   $('#whb *').mouseout(function(){
    $('#whb').remove();
   });

  }
 });
 
 
 
 
  
 
 
 
 
 
/*
 if (navigator.appName.indexOf("Internet Explorer") != -1)
{
  window.setTimeout(function(){
  h = document.getElementById('sn').offsetHeight -  2;
  $('#sn div.cfh').css('height',h);
  $('#sn div.c25r').css('height',h);
},100);
}
*/

   $('#ph').click(function(){
     $('#productlist').show('blind',function(){
       aktiv = true;
     });
   });
   
   $("#ph").parents().click(function(){
     if(aktiv)
     {
        out();
     }
   });
   
   
    
   

});


  $(document).ready(function() {
     $('#example1').bxSlider({
        mode: 'slide',
        speed: 250,
        wrapper_class: 'example1_container',
        auto: 'true',
        width: 230,
        pause: 10000,
        next_text: 'weiter',
     	prev_text: 'zur&uuml;ck',
        controls: false    
     }); 
	    }); 
  

   
function out() 
{
   aktiv = false;
   $('#productlist').hide('blind');
} 
 
 
 /*
	$(function() {
           $("#p").autocomplete({
             source: availableTags
           });
	});
*/

/*
	$(function() {
		$('#p').autocomplete({
			minLength: 0,
			source: projects,
			focus: function(event, ui) {
				$('#p').val(ui.item.label);
				return false;
			},
			select: function(event, ui) {
				//$('#p').val(ui.item.label);
				//$('#url').val(ui.item.value);
    window.location.href = ui.item.value;
				return false;
			}
		})
		.data( "autocomplete" )._renderItem = function( ul, item ) {
			return $( "<li></li>" )
				.data( "item.autocomplete", item )
				.append( "<a>" + item.label + "</a>" )
				.appendTo( ul );
		};
	});
*/


	$(function() {

 
        $("a[rel=lightbox[roadtrip]]").ooBox({        
          title:"alt",
          titlePos:"top",
          type:"roadtrip",
          auto:"on",
          language:"de",
          textCloseDe:"schliessen X"
       });
        $("a[rel=lightbox[KlebebindungList]]").ooBox({        
          title:"none",
          titlePos:"none",
          type:"roadtrip",
          auto:"on",
          language:"de",
          textCloseDe:"schliessen X"
       });
        $("a[rel=lightbox[TerminatorList]]").ooBox({        
          title:"none",
          titlePos:"none",
          type:"roadtrip",
          auto:"on",
          language:"de",
          textCloseDe:"schliessen X"
       });
        $("a[rel=lightbox[SpiralblockList]]").ooBox({        
          title:"none",
          titlePos:"none",
          type:"roadtrip",
          auto:"on",
          language:"de",
          textCloseDe:"schliessen X"
       });
 
   $('a.produkte span img, a.produkter span img, ').mouseover(function(){
       $(this).parent().animate({
          backgroundColor: '#aac4dd'
        }, 500, function() {
          // Animation complete.
        });
   });
   $('a.produkte span img, a.produkter span img').mouseout(function(){
       $(this).parent().animate({
          backgroundColor: '#000'
        }, 500, function() {
          // Animation complete.
        });
   });
   
   
   
       $("h3", "#accordion").click(function(e) {
                if($(this).find("a").attr("href") == "#") return false;
                var contentDiv = $(this).next("div");
                contentDiv.load($(this).find("a").attr("href"));      
        });   
   
   
	});

 
 function pro()
 {
  window.location.href = $('#url').val();
 }
 
 
 

