Post

Replies

Boosts

Views

Activity

Comment on So in ios 17, I stored the login information in NSUserDefaults, and I opened the App again and the login information disappeared
let defaults = UserDefaults.standard defaults.set(NSDate(), forKey: "loginDate") let memberId = data["member_id"] as! Int defaults.set(NSNumber(value: memberId ), forKey: "memberId") defaults.set(data["reg_phone"], forKey: "regPhone") defaults.set(data["reg_phone"], forKey: "recordPhone") defaults.set(data["ship_name"], forKey: "shipName") defaults.set(data["user_name"], forKey: "userName") defaults.synchronize()
Feb ’24