본문 바로가기

모바일/IOS35

Missing Purpose String in Info.plist File 빌드해서 올렸더니 빌드내역(바이너리)이 사라졌다. 왜인지 몰라서 구글링했더니 메일을 살펴보라고하던데메일을 살펴보니 해당 메일이 도착해있었다. Dear Developer, We identified one or more issues with a recent delivery for your app, "앱이름". Please correct the following issues, then upload again. Missing Purpose String in Info.plist File - Your app's code references one or more APIs that access sensitive user data. The app's Info.plist file should contain a NSPhot.. 2018. 11. 27.
dismiss할때 데이터를 함께 전송 https://learnappmaking.com/pass-data-view-controllers-swift-how-to/Passing Data Back With Properties And Functions (A ← B)위의 예제에 나오는 3번형태를 이용 2018. 5. 3.
Alamofire MultipartForm 1 . 홈페이지https://github.com/Alamofire/Alamofire/blob/master/Documentation/Usage.md#uploading-multipart-form-data 2. 추가 정보https://medium.com/@hanifsgy/alamofire-multipart-with-parameters-upload-image-from-uiimagepickercontroller-swift-a4abada24ae 3. 적용정보 let parameters: Parameters = [] Alamofire.upload( multipartFormData: { multipartFormData in for (key,value) in parameters { multipartFormData.app.. 2018. 4. 30.
응용 프로그램을 위한 유효한 ‘aps-environment’ 인타이틀먼트 문자열을 찾을 수 없습니다. 응용 프로그램을 위한 유효한 ‘aps-environment’ 인타이틀먼트 문자열을 찾을 수 없습니다. Capabilities부분에 Push Notifications가 On되어있는지 확인해볼것 2018. 4. 25.
FCM 앱에서 메시지 수신 파이어베이스에 적혀있는 내용https://firebase.google.com/docs/cloud-messaging/ios/receive?hl=ko퀵스타트 정보https://github.com/firebase/quickstart-ios/blob/7e1bae6dd76994c468bd7e1a1f695d8815e6f2da/messaging/MessagingExampleSwift/AppDelegate.swift#L116-L154 앱이 동작중일때도 푸쉬가 뜨게 하려면completHandler부분을 설정할것 completionHandler([.alert, .sound]) 2018. 4. 25.
WKWebview에서 자바스크립트 호출 일반웹뷰라면 밑에 링크가 맞는데https://stackoverflow.com/questions/36139062/call-swift-function-with-javascript-using-uiwebviewWKWebView에서는 변화사항이 있는거같다.https://stackoverflow.com/questions/40761218/javascript-call-to-swift-from-uiwebview사용된정보https://styleshare.github.io/2016/09/14/ios-10-url-open.htmlhttps://samwize.com/2016/06/08/complete-guide-to-implementing-wkwebview/https://gist.github.com/starhoshi/efde2.. 2018. 4. 24.
공유하기 UIActivityViewController 공유하기UIActivityViewControllerhttps://developer.apple.com/documentation/uikit/uiactivityviewcontroller공유하기 제외타입UIActivityTypehttps://developer.apple.com/documentation/uikit/uiactivitytype let text = "공유" let url = "http://google.com" let img = UIImage(named: "login_logo") let activityVC = UIActivityViewController(activityItems:[text,url,img ?? ""], applicationActivities: nil) //공유하기에서 제외할 타입들 acti.. 2018. 3. 2.
무한스크롤 infinite scroll 아래쪽 테이블뷰를 하면서무한스크롤 관련에 대한 내용을 많이봤지만 버그가 많거나 작동이 이상했다. 적용할 클래스에 스크롤뷰 델리게이트를 추가후 UIScrollViewDelegate 로딩중 불러오는걸 방지하기위한 변수를 하나 세팅하고 scrollViewDidEndDecelerating 를 통해서 해결했다. var isMoreDataDownLoading = false func scrollViewDidEndDecelerating(_ scrollView: UIScrollView) { if(scrollView.contentOffset.y != 0){ guard !isMoreDataDownLoading else {return} activityIndicatior.startAnimating() UIApplication... 2018. 2. 27.
how to open an URL in Swift https://stackoverflow.com/questions/39546856/how-to-open-an-url-in-swift3 guard let url = URL(string: "http://www.google.com") else { return //be safe } if #available(iOS 10.0, *) { UIApplication.shared.open(url, options: [:], completionHandler: nil) } else { UIApplication.shared.openURL(url) } Above answer is correct but if you want to check you canOpenUrl or not try like this.let url = URL(str.. 2018. 2. 23.