Hallo zusammen,
ich habe hier auf der Seite ein Javascript gefunden welche auch gut funktioniert.
Wenn ich es aber in perl einbette geht es mit folgender Fehlermeldung nicht mehr.
Fehler: 'parent.frames.1.location'ist Null oder kein Objekt
Sogeht es es:
<script type="text/javascript">
<!--
function Go(x) {
if(x == "nothing") {
document.forms[0].reset();
document.forms[0].elements[0].blur();
return;
}
else if(x == "end")
top.location.href = parent.frames[1].location;
else {
parent.frames[1].location.href = x;
document.forms[0].reset();
document.forms[0].elements[0].blur();
}
}
//-->
</script>
So geht es nicht:
print "<script type="text/javascript"> \n";
print "<!-- \n";
print "function Go(x) { \n";
print "if(x == "nothing") { \n";
print "document.forms[0].reset(); \n";
print " document.forms[0].elements[0].blur(); \n";
print " return; \n";
print " } \n";
print " else if(x == "end") \n";
print " top.location.href = parent.frames[1].location; \n";
print " else { \n";
print " parent.frames[1].location.href = x; \n";
print " document.forms[0].reset(); \n";
print " document.forms[0].elements[0].blur(); \n";
print " } \n";
print "} \n";
print "//--> \n";
print "</script> \n";
Vielen Dank für die Hilfe!
Gruß
Markus