hide/show a image in jquery

前端 未结 7 1438
逝去的感伤
逝去的感伤 2021-02-14 16:57

How to show/hide the image on clicking the hyperlink?



        
7条回答
  •  醉梦人生
    2021-02-14 17:51

    I know this is an older post but it may be useful for those who are looking to show a .NET server side image using jQuery.

    You have to use a slightly different logic.

    So, $("#<%=myServerimg.ClientID%>").show() will not work if you hid the image using myServerimg.visible = false.

    Instead, use the following on server side:

    myServerimg.Style.Add("display", "none")
    

提交回复
热议问题