2

I created an android webview for my website all was going fine only for me to notice that filechooser was not opening in android versions less than 5.0... After struggling for days, and trying so many things like solutions to SO questions 28600165 and 23568792 many other bunch of stuff online... nothing worked out(I bet you all of them are a waste of time). I later found it's a bug in older android versions and there's no real workaround like in this github issue No workaround for filechooser bug for 4.4.1 and 4.4.2 ... But I am able to upload files on all android versions using FireFox for android even Chrome... How come the HTML input type file works with FireFox webviews despite the bug in these particular versions of android... Is it possible for me to power my webviews with FireFox code since it's opensource if yes how easy is that and how effective will it be.... I will also appreciate guidelines on how to go about this, with an example if possible . thanks in advance.

Community
  • 1
  • 1
Fenn-CS
  • 863
  • 1
  • 13
  • 30
  • 1
    Not sure about firefox but you can try Crosswalk embedding API for android. https://crosswalk-project.org/ --- https://crosswalk-project.org/documentation/apis/embedding_api.html – Tasos Aug 18 '16 at 00:53
  • @Tasos thanks let me check that out. – Fenn-CS Aug 18 '16 at 10:27
  • Skip what they say in the installation part here https://crosswalk-project.org/documentation/android/embedding_crosswalk.html -- you can add dependency in the Gradle -- http://stackoverflow.com/questions/28781803/embed-crosswalk-in-android-studio -- change the version numbers to the latest -- curent ( 20.50.533.12 ) -- https://crosswalk-project.org/documentation/downloads.php -- go back to the get started guide here https://crosswalk-project.org/documentation/android/embedding_crosswalk.html -- carry on from step ( Add code to integrate the webview ) -- you be up and running in 5 minutes – Tasos Aug 18 '16 at 13:21
  • Hello @Tasos I ran into problems with the File picker of crosswalk still the issue reported https://crosswalk-project.org/jira/browse/XWALK-2972 and a fix here https://github.com/crosswalk-project/crosswalk/pull/2647 but the fix was rejected though it works I want to apply the fix personally for my project any ideas on that? thanks for your support... – Fenn-CS Aug 19 '16 at 12:48
  • what files are you trying to access?? – Tasos Aug 19 '16 at 13:11
  • Trying to upload images, the file chooser opens on some devices but no uploads happens, after file is selected nothing actually happens – Fenn-CS Aug 19 '16 at 13:39
  • Maybe you need to try Cordova then , because that exposes the android API's to do the work Natively rather than browser inbuilt API's. check this video https://www.youtube.com/watch?v=APGeUO4tAXg – Tasos Aug 19 '16 at 14:07
  • This video better explains it Using Cordova https://www.youtube.com/watch?v=2EjXEfTMHp0 – Tasos Aug 19 '16 at 14:15
  • Ok, thanks, I tried cordova but it did work normally with java code, needed me to write some javascript(Meaning I have to modify my remotes site javascript), I already have a remote website all I need is a mobile app that allows the upload button work... – Fenn-CS Aug 19 '16 at 14:18
  • If you cant find a solution then you need to write Native code to handle the Uploads and use the Android Webview -- http://stackoverflow.com/questions/4126625/how-do-i-send-a-file-in-android-from-a-mobile-device-to-server-using-http – Tasos Aug 19 '16 at 14:24
  • Mozilla is currently working on this but they don't consider it ready yet https://wiki.mozilla.org/Mobile/GeckoView – jobukkit Aug 02 '17 at 22:16

0 Answers0