Receive URL in Ionic for ios

后端 未结 6 1864
逝去的感伤
逝去的感伤 2021-02-02 11:11

I am using ionic framework. I\'m trying to set up a way to receive a url from another app. Like, you are in browser, click share, and send the link to another app (my app). I fo

6条回答
  •  醉话见心
    2021-02-02 11:42

    All you need is Custom-URL-scheme cordova plugin.

    You can do it manually also. For iOS add to your *.plist. Or You can look at Step 5

    CFBundleURLTypes
    
      
        CFBundleURLSchemes
        
          URL_SCHEME
        
      
    
    

    In iOS after adding custom scheme it automatically calls a function called handleOpenURL.

    For android add AndroidManifest:(In android you can even listen http scheme)

    
        
            
            
            
            
            
        
    
    

提交回复
热议问题