Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $.ajax({
- type: "GET",
- url: "Home/LogIn",
- data: { userName: username, password: password },
- dataType: 'json',
- succes: function (data) {
- alert(data.d + ' Succes')
- },
- failure: function (data) {
- alert(data.d + ' failure');
- }
- });
- public string LogIn(string userName, string password)
- {
- LogInController loginController = (LogInController)Session["LogInController"];
- User tempuser = loginController.CheckLogin(password, userName);
- if (tempuser != null)
- {
- massdrop = new MassdropShop(tempuser);
- Session["LoggedInName"] = tempuser.Name;
- Session["massdrop"] = massdrop;
- return "1";
- }
- else
- return "0";
- }
- succes: function (data) {
- alert(data.d + ' Succes')
- },
- success: function (data) {
- alert(data.d + ' Succes')
- },
- data:{ userName: username, password: password },
- change
- data:JSON.stringify{ userName: username, password: password },
- success: function (data) {
- alert(JSON.stringify(data.d));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement