private DMMAjaxResult GetFormTokens(string pageToken, string dmmToken) { Dictionary <string, string> postDic = new Dictionary <string, string>(); Dictionary <string, string> customHeader = new Dictionary <string, string>(); customHeader["X-Requested-With"] = "XMLHttpRequest"; customHeader["DMM_TOKEN"] = dmmToken; postDic["token"] = pageToken; string jsonResult = ""; helper.CTRHttp(LoginAjax, LoginPage, postDic, customHeader, ref jsonResult); DMMAjaxResult ajaxResult = JsonConvert.DeserializeObject <DMMAjaxResult>(jsonResult); return(ajaxResult); }
private void LoginDMM(DMMAjaxResult formToken) { string loginResult = ""; Dictionary <string, string> postDic = new Dictionary <string, string>(); postDic["token"] = formToken.token; postDic["login_id"] = _username; postDic["save_login_id"] = "0"; postDic["password"] = _password; postDic["save_password"] = "******"; postDic["use_auto_login"] = "******"; postDic[formToken.login_id] = _username; postDic[formToken.password] = _password; postDic["path"] = LoginPagePath; postDic["prompt"] = ""; postDic["client_id"] = ""; postDic["display"] = ""; helper.CTRHttp(LoginAuth, LoginPage, postDic, ref loginResult); }