So I am still working on my first PHP page (you can call me newb)and want to use the mouseover on the results of my query. How do I get that to work. I know I have to identify it as Java Script and I am having a hard time finding out where or how.
Here is my code thus far (excuse the bad form please):
<HTML>
<BODY>
<p>If you do not have XP and need the client click <a href="http://tsweb.idns.direcpc.com/tcweb/client.zip">here</a> </p></n>
<?php
include("./header.php");
$connID = connect_to_techsupport();
$query = "SELECT server_name.server_id, server_name.ServerName, server_description.description, datacenter_name.datacenter, server_description.row, server_description.rack, server_description.ipaddress, server_description.datacenter_id
FROM server_name, server_description, datacenter_name
WHERE server_name.server_id = server_description.server_id
AND datacenter_name.datacenter_id = server_description.datacenter_id
ORDER BY server_name.ServerName";
echo '<table border ="0" width="%80" cellspacing="1" cellpadding="1" align="center">
<tr>
<td align="left" width="20%"><b>Server Name</b></td>
<td align="left" width="35%"><b>Description</b></td>
<td align="left" width="10%"><b>Datacenter</b></td>
<td align="left" width="5%"><b>Row</b></td>
<td align="left" width="5%"><b>Rack</b></td>
<td align="left" width="15%"><b>IP Address</b></td>
</tr>';
$result = mysql_query($query);
while ($row = mysql_fetch_array ($result, MYSQL_ASSOC)) {
echo " <tr onmouseover=\"setPointer(this,8,'over','#DDDDDD','#CCFFCC','#FFCC99');\"
onmouseout=\"setPointer(this,8,'out','#DDDDDD','#CCFFCC','#FFCC99');\"
onmousedown=\"setPointer(this,8,'click','#DDDDDD','#CCFFCC','#FFCC99');\">
<td align=\"left\"><a href=\"start_session_new.php?serverid={$row['server_id']}\">{$row['ServerName']}</a></td>
<td align=\"left\">{$row['description']}</td>
<td align=\"left\">{$row['datacenter']}</td>
<td align=\"left\">{$row['row']}</td>
<td align=\"left\">{$row['rack']}</td>
<td align=\"left\">{$row['ipaddress']}</td>
</tr>\n";
}
echo '</table>';
mysql_close();
?>
</BODY>
</HTML>
I am creating a page that users can go to and connect to a server via Terminal Server Client. It works, but I want to highlight the line that the mouse is over so the user can easily read the line.
Thanks for any help