Hej NG,
jeg har problemer med at få mit javascript til at virke, det er godt nok en
php side, men det er clientside scriptet der failer...
er der nogen der ved hvorfor den ikke vil åbne et nyt vindue når man klikker
på <tr> ??
<?php
$connection = mysql_connect("localhost",
"???????",
"???????");
mysql_select_db("???????", $connection);
?>
<html>
<head>
<title> Links </title>
<link rel="STYLESHEET" type="text/css" href="../include/admin.css">
<script language="JavaScript" src="../include/table.js">
function winPop(url) {
pop = window.open(url,
"linkwindow","toolbar=yes,location=yes,directories=yes,status=tyes,menubar=y
es,scrollbars=yes,resizable=yes,height=500,width=700");
}
</script>
</head>
<body>
<br>
<table align="center" width="80%" cellspacing="1" cellpadding="2"
bgcolor="#dddddd">
<tr>
<td bgcolor="#002550" colspan="4" align="center"><p id=header>Links</td>
</tr>
<tr width="100%">
<td bgcolor="#002550"><p id=header>Title</td>
</tr>
<?php
$result = mysql_query("select * from links where type='1' order by type");
while($row = mysql_fetch_array($result)) {
printf("<tr bgcolor='#ffffff' onMouseOver='tc(this,\"in\");'
onMouseOut='tc(this,\"out\");' onMouseDown='tc(this,\"down\");'
onMouseUp='tc(this,\"up\");' onClick='winPop(\"%s\");'>",$row[url]);
printf(" <td><p>%s</td>",$row[title]);
print("</tr>");
}
?>
</table>
</body>
</html>
|