// Add javascript to change the styles or you can do this
// in your code behind.
var arrImages = document.getElementsByTagName("img");
for(var i = 0; i < arrImages.length; i++)
{
arrImages[i].style.cursor = 'hand';
arrImages[i].onmouseover = function() {
this.style.background = '#333333';
}
arrImages[i].onmouseout = function() {
this.style.background = '#ffffff';
}
}
Marked as answer by Vince Xu - MSFT on Dec 27, 2007 09:20 AM
triggered
Contributor
3356 Points
908 Posts
Re: How to make photos "appear clickable" ?
Dec 23, 2007 02:00 AM|LINK
In addition to changing the cursor to "hand", changing the colors of the borders makes it appear clickable as well.
for instance,
<asp:Image ID="iMyImage" runat="server" ... ></asp:Image>
// Add javascript to change the styles or you can do this // in your code behind. var arrImages = document.getElementsByTagName("img"); for(var i = 0; i < arrImages.length; i++) { arrImages[i].style.cursor = 'hand'; arrImages[i].onmouseover = function() { this.style.background = '#333333'; } arrImages[i].onmouseout = function() { this.style.background = '#ffffff'; } }