///////////////////////////////////////////////////////////////////
////////// Textcounter /////////////////////////////////////////

function textCounter(field, countfield, maxlimit) {
if (field.value.length > maxlimit)
field.value = field.value.substring(0, maxlimit);
else
countfield.value = maxlimit - field.value.length;
}
////////////////////////////////////////////////////////////////////
//////////// Favoriten hinzufügen ////////////////////////////////

function addFavorite() {
bookmarkurl=self.location.href;
bookmarktitle=document.title;
if (document.all) {
window.external.AddFavorite(bookmarkurl,bookmarktitle)
} else alert("Bitte bei Netscape STRG + D drücken");

}

////////////////////////////////////////////////////////////////////
//////////// Region wechseln ////////////////////////////////
  function changeRegion0() {
    var Pos = document.regional.region.options.selectedIndex;
    var newReg =  document.regional.region.options[Pos].value;
    if (newReg.length > 0 && newReg != "") {
      location.href = "http://"+newReg+".procy.de/";
    }
  }

  function changeRegion1() {
    var Pos = document.regional.region.options.selectedIndex;
    var fos = document.getElementById("makeit").value;
    var newReg =  document.regional.region.options[Pos].value;
    if (newReg.length > 0 && newReg != "") {
      location.href = "http://"+newReg+".procy.de/"+fos;
    }
  }

  function changeCategory() {
    var Pos = document.dirCategory.caty.options.selectedIndex;
    var newCat =  document.dirCategory.caty.options[Pos].value;
    if (newCat.length > 0 && newCat != "" && newCat != "0") {
    	if (newCat == "2000") {
	      location.href = "auto_transport_logistik.html"; }
    	if (newCat == "2500") {
	      location.href = "bauen_renovieren.html"; }
    	if (newCat == "5002") {
	      location.href = "beauty_wellness.html"; }
    	if (newCat == "3500") {
	      location.href = "beratung_hilfe.html"; }
    	if (newCat == "1600") {
	      location.href = "beruf_karriere.html"; }
    	if (newCat == "7000") {
	      location.href = "betreuung_pflege.html"; }
    	if (newCat == "3000") {
	      location.href = "buero_finanzen.html"; }
    	if (newCat == "5000") {
	      location.href = "fitness_erholung.html"; }
    	if (newCat == "1300") {
	      location.href = "freizeit_unterhaltung.html"; }
    	if (newCat == "1400") {
	      location.href = "gesundheit_medizin.html"; }
    	if (newCat == "1000") {
	      location.href = "haus_garten.html"; }
    	if (newCat == "8000") {
	      location.href = "minijobs.html"; }
    	if (newCat == "7500") {
	      location.href = "haustiere_zoo.html"; }
    	if (newCat == "1200") {
	      location.href = "internet_computer.html"; }
    	if (newCat == "1500") {
	      location.href = "kinder.html"; }
    	if (newCat == "6500") {
	      location.href = "kunst_kreativ.html"; }
    	if (newCat == "3700") {
	      location.href = "marketing_werbung.html"; }
    	if (newCat == "4500") {
	      location.href = "multimedia.html"; }
    	if (newCat == "5500") {
	      location.href = "party_catering_event.html"; }
    	if (newCat == "6000") {
	      location.href = "unterricht_workshops_nachhilfe.html"; }
    	if (newCat == "8500") {
	      location.href = "urlaub_reisen.html"; }
    	if (newCat == "8600") {
	      location.href = "nahrung_genuss.html"; }
    	if (newCat == "6101") {
	      location.href = "geschenkideen_geschenkideen_6100_6101_1.html"; }
    	if (newCat == "8564") {
	      location.href = "sonstiges_sonstiges_8565_8564_1.html"; }
    }
  }