Click to See Complete Forum and Search --> : link for a <div>


webtekie
08-19-2003, 10:21 AM
Hi guys,

I have a layer in IE, is it possible to make it so when layer is clicked on user is redirected to another page. Same thing as <a href>link</a> works but only with <div>. I tried surrounding the whole <div> in <a href> but it does not seem to work. Any suggestions?


<div style="position:right;
width:226px;
height:15px;
left: 0px;
top: 123px;
background-color: #ffcc33;
z-index: 2;
padding: 3px 3px 3px 3px;
border-style: solid;
border-color: #000000;
border-width: 1px;
text-align: right;
visibility:visible">
<table cellspacing="1"
cellpadding="0"
cellpadding="0"
border="0">
<tr>
<td><img src="generic_images/notify.gif"
valign="botton">
</td>
<td class="pswd">
&nbsp;
<%=expireMsg%>
</td>
</tr>
</table>
</div>


thanks,
webtekie

Fang
08-19-2003, 10:34 AM
Wrapping the <div> with a <a> does work.

webtekie
08-19-2003, 10:44 AM
not with mine...when I hover over <div> in status bar I see url that I want to go to. However, when I click on <div> pointer changes to hand but nothing happens.

webtekie
08-19-2003, 11:07 AM
Made a workaround, inside <div>:
onClick="javascript:window.location='page.jsp';"