<input type="button" class="write_button" value="Write" onclick = "window.open('Write.aspx','Write');"/>
目前我正在使用 window.open
来测试按钮是否移动到定向 .aspx
文件。但“window.open
”提供的一件事是它打开新窗口。我搜索了一些与 onclick
相关的选项,并打开,但我不确定如何移动到现有页面上上传的不同 .aspx
文件。
最佳答案
使用这个:-
window.open("Write.aspx","_self")
或:-
location.href = "Write.aspx";
关于javascript - 移动 .aspx 文件时的 onclick 属性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31559492/