Menu med rollover
jeg vil gerne have at min menutekst er en farve når men ikke er på siden og en anden når man er på siden, hva gør jeg.Jeg har skrevet følgende, men det fungere ikke helt og jeg kan ikke helt se hvordan jeg kommer vidre??
<%
Dim ID, M_ID, MOVER, MOUT
ID = REQUEST.QUERYSTRING("P_ID")
MOVER = "#fb7000"
MOUT = "#FFFFFF"
IF ID = "" THEN
ID = "1"
END IF
strDNS = "driver={MySQL};server=mysql5.123hotel.dk;uid=xxx;pwd=xxx;database=xxx_dk_db"
set rsmenu = Server.CreateObject("ADODB.Recordset")
strSQLmenu = "SELECT * FROM VT_PAGES WHERE PAGES_LEVEL = 1 AND PAGES_STATUS = 1"
rsmenu.open strSQLmenu,strDNS
' om siden er aktiv
IF int(ID) = int(RSmenu("PAGES_ID")) THEN
FontColor = "" & MOVER
ELSE
FontColor = "onmouseover=this.bgColor='"&MOVER&"' onmouseout=this.bgColor='"&MOUT&"'"
END IF
'ikon
%>
<table width="745" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="212" height="50"><img src="pic/omfirmaet_pic.jpg" width="212" height="50" border="0" usemap="#Map"></td>
<td width="10" height="50" background="pic/bg_menu.gif"><img src="pic/trans.gif" width="10" height="1"></td>
<%
RESPONSE.WRITE "<td width='150' background='pic/bg_menu.gif'><div align='center'><a href='kompetencer.asp?p_id=145'><font color='#"&FontColor&"'>KOMPETENCER</font></a></div></td>"
RESPONSE.WRITE "<td width='11' background='pic/bg_menu.gif'><img src='pic/dot.jpg' width='11' height='50'></td>"
RESPONSE.WRITE "<td width='150' background='pic/bg_menu.gif'><div align='center'><a href='referencer.asp?p_id=146'><font color='#"&FontColor&"'>REFERENCER</font></a></div></td>"
RESPONSE.WRITE "<td width='11' background='pic/bg_menu.gif'><img src='pic/dot.jpg' width='11' height='50'></td>"
RESPONSE.WRITE "<td width='80' background='pic/bg_menu.gif'><div align='center'><a href='job.asp?p_id=147'><font color='#"&FontColor&"'>JOB</font></a></div></td>"
RESPONSE.WRITE "<td width='11' background='pic/bg_menu.gif'><img src='pic/dot.jpg' width='11' height='50'></td>"
RESPONSE.WRITE "<td width='100' background='pic/bg_menu.gif'><div align='center'><a href='kontakt.asp?p_id=148'><font color='#"&FontColor&"'>KONTAKT</font></a></div></td>"
%>
<td width="10" background="pic/bg_menu.gif"><img src="pic/trans.gif" width="10" height="1"></td>
</tr>
</table>
<%
rsmenu.CLOSE
SET rsmenu=NOTHING
%>