25. august 2004 - 23:08
Der er
9 kommentarer og 1 løsning
Onclik til iframe
Hvordan for jeg "onclik" til at virke med target? Virker: <a href=test.php?var=11 target='IframeName2'>prøv</a> Virker ikke: onclick="location.href='test.php?var=11 'target='IframeName2';"
Annonceindlæg fra HP
27. august 2004 - 00:19
#7
<a href="#" onclick="window.frames[IframeName2].location.href='test.php?var=11';return false;">prøv</a> Medfør "Der opstod fejl på side" <a href=test.php?var=11 target='IframeName2'>prøv</a> Virker Her test kode: <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"> <title>prøv</title> </head> <body> <table border="0" cellpadding="0" cellspacing="0" width="928" height="322"> <!-- MSTableType="layout" --> <tr> <td valign="top"> <a href="#" onclick="window.frames[IframeName2].location.href='test.php?var=11';return false;">prøv</a> <br> <a href=test.php?var=11 target='IframeName2'>prøv</a> </td> <td valign="top" height="44"> <!-- MSCellType="ContentHead" --> </td> </tr> <tr> <td valign="top" width="160"> <iframe frameborder="0" width="267" height="409" scrolling="auto" src="test_a.php" name="IframeName1" class="iframe"></iframe></td> <td valign="top" height="278" width="768"> <iframe frameborder="0" width="267" height="409" scrolling="auto" src="test.php" name="IframeName2" class="iframe"></iframe></td> </tr> </table> </body> </html>
27. august 2004 - 15:10
#10
mm12010: Det virker nu fint i testkode men ikke hvis jeg bruger det i en "<tr>". Kode: <tr onclick="window.frames['IframeName2'].location.href='test.php?var=11';return false;" class="txtBlack" style="cursor:hand;padding:1px;background-color:<? echo $bf; ?>;" onmouseover='trcol(this,"#3399CC");' onmouseout='trcol(this,"<? echo $bf; ?>");'>