Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-11352

WKWebView doesn't apply User-Agent configuration

    XMLWordPrintableJSON

Details

    Description

      config.xml contains

      <preference name="AppendUserAgent" value="something/version"/>
      

      This is properly used for Android (cordova-android 5.1.1), but not with iOS+WKWebView (cordova-ios 4.1.1).

      The cause is actually "documented": CDVUserAgentUtil:setUserAgent says that the default settings must be registered before the webview is actually instantiated. But, CDVViewController:viewDidLoad delays the call to setUserAgent until after the view has been created.

      AFAIR this worked with the UIWebView.

      Attachments

        Issue Links

          Activity

            People

              shazron Shazron Abdullah
              ankon Andreas Kohn
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: