var counter=1;
var maxlevel=3;
var titles = ["Νικόλαος Γύζης - Ο ζαχαροπλάστης,1898", "Γεώργιος Ιακωβίδης - Παιδική Συναυλία,1894 (λεπτομέρεια)", "Βίλχεμ Τρούμπνερ,«Σκύλος και λουκάνικο στο πιάτο»,1878"];

function next(){
if (counter<maxlevel) {
counter=counter+1;
document.getElementById("leftimage").src="images/image"+counter+".jpg";
document.getElementById("lezand").innerHTML=titles[counter-1];
}
if (counter==maxlevel) document.getElementById("nextbutton").style.visibility='hidden';
document.getElementById("previousbutton").style.visibility='visible';
}

function previous(){
if (counter>1) {
counter=counter-1;
document.getElementById("leftimage").src="images/image"+counter+".jpg";
document.getElementById("lezand").innerHTML=titles[counter-1];
}
if (counter==1) document.getElementById("previousbutton").style.visibility='hidden';
document.getElementById("nextbutton").style.visibility='visible';
}

