window.open Dauerfehler

Dennis-S.

Erfahrenes Mitglied
Also ich bin am verzweifeln, ich finde den Fehler nicht. Immer wenn im Browser das Fenster bzw. die Fenster geöffnet werden sollen. KOmmt in die Meldung "Fehler auf der Seite" und nichts tut sich. WO ist der Fehler?!?!

MfG schonmal Danke

Code

<script language="JavaScript">

function opengrill01() {
window.open('http://www.8ung.at/dennis-s/grill01.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill02() {
window.open('http://www.8ung.at/dennis-s/grill02.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill03() {
window.open('http://www.8ung.at/dennis-s/grill03.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill04() {
window.open('http://www.8ung.at/dennis-s/grill04.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill05() {
window.open('http://www.8ung.at/dennis-s/grill05.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill06() {
window.open('http://www.8ung.at/dennis-s/grill06.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill07() {
window.open('http://www.8ung.at/dennis-s/grill07.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill08() {
window.open('http://www.8ung.at/dennis-s/grill08.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill09() {
window.open('http://www.8ung.at/dennis-s/grill09.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
function opengrill10() {
window.open('http://www.8ung.at/dennis-s/grill10.html', 'Grillabend am 7. Mai 2003', 'height=800, width=600, scrollbars=yes');
void(0);
}
</script>
 
1.: Du darfst keine Leerzeichen im Namen des Fensters verwenden (2. Parameter von open()).

2.: Du kannst dir die ganzen Funktionen ersparen:
PHP:
function opengrill(nummer) {
  window.open('http://www.8ung.at/dennis-s/grill'+nummer+'.html', 'Grillabend', '...');
}

//Aufruf:

<a href="" onClick="opengril('05'); return false;">Klick</a>
 
Zurück