I am just trying to do a very basic task to make sure my Login button is firing before i start coding up the logic.
Here is my button :
<input type="submit" name="login-submit" runat="server" id="btnLogin" class="form-control btn btn-login" value="Log In" onserverclick="btnLogin_Click"/>
Here is my code behind :
protected void btnLogin_Click(object sender, EventArgs e)
{
usernameLogin.Value = "Hello";
}
Nothing is happening though, I don't know what I could be missing, I am guessing its a tag in the input type
.... Any ideas?
It is not even hitting my breakpoint
使用<button>
标记而不是<input>
, OnServerClick
是HtmlButton
方法
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.