Button button how to achieve hyperlinks

Reprinted from: https://www.cnblogs.com/Renyi-Fan/p/8945820.html

 

 

A summary

1, I realized hyperlink button by button embedded in a label to achieve

<button class="am-btn am-btn-default am-btn-xs am-text-danger "><a href="{:url('discipline/delete',array('id'=>$vo.id))}"><span class="am-icon-trash-o"></span> Delete</a></button>

2, when the form is submitted the form which that action can be achieved jump

3, one more point, to give what elements not only add style can be defined style properties of the element can also be put on the outside div, span style it

4, the following questions and answers from the inside point of view, button label is achieved by a hyperlink onclick event to solve

5 obviously onclick event to achieve a hyperlink embedded in a hyperlink tag to achieve better than the button label because a label text will change color

 

Second, the problem

http://zhidao.baidu.com/question/41167708.html
I tried in the asp pages, <input type = button onclick = "window.open ( ' Connect')"> valid, but <input type = button onclick = "window.location.href ( 'connect')"> did not respond, how is this going ah?
I added in the button link is result.asp action = all: add? 
Result.asp and is the current page in the same directory, but I added a name-value pair in the back action = all
Click on seemingly added after He did not respond, and how to solve it? Back links can not add value name right?

 

Third, the answer

Yes might browser compatibility issues, you write code that can run in IE. But not Firefox. It gives you the standard wording. 

<INPUT type = Button the onclick = "the window.open ( '1.asp')">
<INPUT type = Button the onclick = "window.location.href = '1.asp' ">

 

Guess you like

Origin www.cnblogs.com/yanyanstyle/p/11354562.html