How to make a submit button display as a link?

后端 未结 8 876
春和景丽
春和景丽 2020-12-03 06:51

This is not working in IE:

.text-button { background: transparent; 
               text-decoration: none; 
               cursor: pointer; }





        
8条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-03 07:39

    I believe the answer submitted above by mofolo is the more correct solution

    CSS styling of submit buttons to make them look like anchor tags does NOT cross browser. The text-decoration:underline style is ignored by many browser types.

    The best method in my experience is to use javascript on an anchor tag's onclick event.

    For example:

    A "Delete" link on a user details form screen, with confirmation before submitting the form with an id of "userdetails"

    Delete
    

提交回复
热议问题