I am requesting a website using cordova inappbrowser
This website works correctly if we load it via desktop but not from mobile. Do you have any idea what might be the issue? You can view the live website as well. When I load it from mobile using "Request Desktop Website" in chrome or firefox (mobile) it works.
Inappbrowser doesn't support user-agent out of the box. Using a simple hack we may force inappbrowser to use cordova webview's user-agent-string.
Open your InAppBrowser.java and edit the run method.
WebSettings settings = inAppWebView.getSettings();
settings.setJavaScriptEnabled(true);
settings.setJavaScriptCanOpenWindowsAutomatically(true);
settings.setBuiltInZoomControls(true);
settings.setPluginState(android.webkit.WebSettings.PluginState.ON);
settings.setUserAgentString(thatWebView.getSettings().getUserAgentString()); // magic line
Find more about "The Hack" here
Now to set cordova user agent string. we will use a plugin cordova-useragent List of user agent string can be found here