前台页面(aspx文件):
--伪装按钮 <span onclick=‘__doPostBack("lkSend","key")‘>发送</span> --隐藏触发按钮 <asp:LinkButton ID="lkSend" OnClick="lkSend_Click" runat="server" Visible="false"></asp:LinkButton>
后台页面(cs文件):
protected void lkSend_Click(object sender, EventArgs e) { string args = Request.Form["__EVENTARGUMENT"]; Response.Write(args); }
就是这么简单!
时间: 2024-10-02 08:18:47