$(document).ready(function() {
var bigHeadFile = Array();
bigHeadFile[0] = ""
bigHeadFile[1] = ""
bigHeadFile[2] = ""
bigHeadFile[3] = ""
var bigHeadDescr = Array();
bigHeadDescr[0] = "
"
bigHeadDescr[1] = "
"
bigHeadDescr[2] = "
"
bigHeadDescr[3] = "
"
$(document).ready(function() {
$('#slideShow').css('background-image','url(/instances//images/bigHead/)');
$('#sliderCaption').html(bigHeadDescr[0]);
});
$(document).ready(function() {
$('.slideShowDot').live('click', function() {
var thisSlideShowDot = this;
var dotImageIndex = $(thisSlideShowDot).index();
// erst ausblenden
$('#slideShow').animate ({
opacity: 0.0
}, 200, function() {
// neues Bild setzen
$('#slideShow').css('background-image','url(/instances//images/bigHead/' + bigHeadFile[dotImageIndex] + ')');
// Bildbeschreibung aktualisieren
$('#sliderCaption').html(bigHeadDescr[dotImageIndex]);
// und wieder einblenden
$('#slideShow').animate ({
opacity : 1
}, 200, function() {
});
});
// activePunkte setzen
$('.slideShowDot').removeClass('slideShowDotActive');
$(this).addClass('slideShowDotActive');
});
});});
////////////////////////////////////////////////////////////////////
// den Header-Slider auf Klick kleiner machen
////////////////////////////////////////////////////////////////////
$('#hideSliderButton').live('click', function() {
// Weiche rein, für schon gedrückt oder auch nicht..
//if ( == 0) {
if ($('#slideShow').height() > 60) {
// Caption und slider rausfaden
$('#changeSlider').fadeOut(200, function() {
$('#sliderCaption').fadeOut(200, function() {
$('#changeSlider').css('top', '90px');
// hintergrundbild ein bisschen verrücken
$('#slideShow').animate({
height : '60px',
backgroundPosition: '0 -25px'
}, 250, function() {
//$('#changeSlider').fadeIn(250, function() {
// den Zustand in ner PHP-Session-Var speichern
$.post( '/setsliderhided', function() {
//location.reload(true);
});
//});
});
});
});
}
//if ( == 1) {
if ($('#slideShow').height() == 60) {
// Caption und slider rausfaden
$('#changeSlider').fadeOut(200, function() {
$('#sliderCaption').fadeIn(200, function() {
$('#changeSlider').css('top', '270px');
// hintergrundbild n bisschen verrücken
$('#slideShow').animate({
height : '300px',
backgroundPosition: '0px 0px'
}, 250, function() {
$('#changeSlider').fadeIn(250, function() {
// neues Hintergrundbild für den ausgelösten Button
//$('#hideSliderButton').animate
// den Zustand in ner PHP-Session-Var speichern
$.post( '/setsliderhided', function() {
//location.reload(true);
});
});
});
});
});
}
});