본문 바로가기
#모바일 [Mobile]/iOS

[iOS] URL 주소를 통해서 사파리에서 열기 (How to open a URL in Safari?)

by cy_mos 2019. 11. 20.
반응형
[iOS] URL 주소를 통해서 사파리에서 열기 (How to open a URL in Safari)

📄 Open a URL in Safari Source Code by Swift

guard let url = URL(string: "https://www.naver.com") else { return }

if UIApplication.shared.canOpenURL(url) {
  UIApplication.shared.open(url, options: [:], completionHandler: nil)
} else {
  // Here, UIApplication.shread.open Error Source Code.
}

🚀 REFERENCE

 

How to open a URL in Safari - free Swift 5.1 example code and tips

Was this page useful? Let us know! 1 2 3 4 5

www.hackingwithswift.com

 

ChangYeop-Yang/Study-iOS

iOS (formerly iPhone OS) is a mobile operating system created and developed by Apple Inc. exclusively for its hardware. It is the operating system that presently powers many of the company's mo...

github.com

반응형

댓글