Hi
i have login as pop up box in master page, and i use jquery to show pop up box
i use asp:button , to onclick ..but function on
<asp:Button ID="psearch" runat="server" onclick="usearch_Click" Text="LOG IN" />
usearch_Click is never called in masterpage.master
Adding code
<input class="loginName required" type="text" id="loginname" value="Username" name="loginName" />
<input class="loginPass required" type="password" id="loginpassword" value="Password" name="loginPass" />
<input type="submit" value="LOG IN" id="LoginBtnValue"/>
on login click
function GetLoginDetails(UserName,UserPassword)
{
var returnurl = window.location.href;
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "Default.aspx/GetLoginDetails",
data: "{'UserName':'" +UserName+ "'," + "'UserPassword':'"+UserPassword +"','returnurl':'"+returnurl+"'}",
success: function(data) {
var theHtml = data.d;
if(data.d=="loginerror")
{
alert('Username or password is incorrect');
}
else
{
window.location.href = data.d;
}
},
error: function(xhr, textStatus, errorThrown) {
alert("Login FAIL: " + xhr + " " + textStatus + " " + errorThrown);
}
});
}
with values
and in default.aspx.cs ,
web method like
[WebMethod]
public static string GetLoginDetails(string UserName, string UserPassword,string returnurl)
{
}
In this i want to
[WebMethod]
public static string GetLoginDetails(string UserName, string UserPassword,string returnurl)
{
}
what i want is to change master page text login to logoff with name (for exp, logoff , welcome name)