saving server via sharedpreferences