Hi,
hab mal wieder ein Problem, und zwar wenn ich auf den Button Zum
Warenkorb klicke dann soll eine Funktion aufgerufen werden, aber sie
startet einfach nicht! Der Button sollte stimmen!
Hier mal der Code:
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Warenkorb</title>
<script type="text/javascript">
function Artikel_schreiben(ArtBezeichnung,ArtMenge,ArtArtNr,ArtAbbildung,ArtEinheit,ArtPreis)
{
document.writeln('<table style="position: absolute; left: 0px; top: 0px;" border="0" cellspacing="0" cellpadding="0" width="300px%" height="250px">');
document.writeln(' <tr>');
document.writeln(' <td bgcolor="#ffe600" align="left" valign="top" colspan="3" width="300px" height="50px%">');
document.writeln(' <img src ="messbar ueberschrift_neu9.gif" align="left" valign="top" width="295px">');
document.writeln(' <p align="center" valign="bottom"><font face="verdana" size="1" color="#4F4F4F">Dieser Artikel wurde dem Warenkorb hinzugefügt</font></p>');
document.writeln(' </td>');
document.writeln(' </tr>');
document.writeln(' <tr>');
document.writeln(' <td align="left" valign="top" width="100px" height="100px">');
document.writeln(' <p align="left" valign="top">[img]+ArtAbbildung+[/img]</p>');
document.writeln(' </td>');
document.writeln(' <td align="center" valign="top" width="200px" height="150px">');
document.writeln(' <p align="Left"><font face="verdana" size="2" color="#4F4F4F">[b]'+ArtBezeichnung+'[/b]</font></p>');
document.writeln(' <p align="Left"><font face="verdana" size="1" color="#4F4F4F">[b]Artikel-Nr.: '+ArtArtNr+'[/b]</font></p>');
document.writeln(' <p align="right" valign="bottom"><font face="verdana" size="2" color"#4F4F4F">'+ArtPreis+' € Endpreis'+'</font></p>');
document.writeln(' </td>');
document.writeln(' </tr>');
document.writeln(' <tr>');
document.writeln(' <td colspan="3" width="300px" height="30px">');
document.writeln(' <div style="float: left;" align="left" valign="top">');
document.writeln(' <input type ="button" style="background-color:#ff9b07" name="bestellen_1" value="Zum Warenkorb" class="schaltflache" onclick="javascript:ShowDocument()">');
document.writeln(' </div>');
document.writeln(' <div style="float: right;" align="right" valign="top" >');
document.writeln(' <input type ="button" style="background-color:#ffe600" name="schliessen" value="zurück zum Shop" onClick="window.close()">');
document.writeln(' </div>');
document.writeln(' </td>');
document.writeln(' </tr>');
document.writeln(' <tr>');
document.writeln(' <td bgcolor="#ff9b07" colspan="3" width="300px" height="10px" valign="bottom">');
document.writeln(' </td>');
document.writeln(' </tr>');
document.writeln('</table>');
}
function ShowDocument()
{
opener.parent.bereich06.location.href="xaranshop_11_1.htm";
}
</script>
</head>
<body>
</body>
</html>
Alles anzeigen
ich weis das es etwas komisch geschrieben ist aber ich musste es so
schreiben da die funktion bereits aus einem anderem Fenster aufgerufen
wird und auch variablen übergibt und wenn ich es im body aufbaun würde
dann tauchen fehler auf weil er dann beim aufbaun schneller sein kann
wie das er die variablen übergeben hat.