+ 4

How can I get the files from Android using browser like Chrome, Mozilla...

I used to see file through a browser(Mozilla) in my pc using the file:// protocol. But how can I use it on Android?

24th Jul 2020, 11:41 AM
MSN
MSN - avatar
15 Answers
+ 6
Your internal storage is mounted to /storage/emulated/0/ So you may place your html in the internal storage and open it through file:///storage/emulated/0/path/to/yourfile.html. But if the device has newer versions of android this might not be possible. In that case open MyFiles on your phone and click on the html file to load it. However in the second case your externally linked js and css files wont load so you would have to place them in your html file only. The best I would recommend is to download Pydroid3 or Qpython and render that file through a flask server, which render the files by location. I would give you the code for mine if you want.
24th Jul 2020, 11:47 AM
Prabhakar Dev
Prabhakar Dev - avatar
+ 5
You can't use the file:// in android due to security issues but i guess it may work with firefox android. It won't with chrome
24th Jul 2020, 12:00 PM
Prabhakar Dev
Prabhakar Dev - avatar
+ 4
Arnesh that method doesn't work for devices with newer versions of android or samsung devices
24th Jul 2020, 11:51 AM
Prabhakar Dev
Prabhakar Dev - avatar
+ 3
MD Abdullah But how?
24th Jul 2020, 11:44 AM
MSN
MSN - avatar
+ 3
In html, you can use input[type="file"] which work in both PC,mobile an you can access any kind of file from user device
25th Jul 2020, 7:45 AM
Master Genius [ INACTIVE ]
Master Genius [ INACTIVE ] - avatar
+ 3
NUHEEN oh I completely misunderstood the question😅🤦‍♂️. Nice answer Master Genius
25th Jul 2020, 7:54 AM
Prabhakar Dev
Prabhakar Dev - avatar
+ 2
NUHEEN yes that is for security. Everytime you click on an html file it is copied to an inaccessible directory by chrome and rendered from there.
24th Jul 2020, 11:55 AM
Prabhakar Dev
Prabhakar Dev - avatar
+ 2
Nice ans Master Genius 👍
25th Jul 2020, 7:46 AM
MSN
MSN - avatar
+ 2
NUHEEN thanks
25th Jul 2020, 8:07 AM
Master Genius [ INACTIVE ]
Master Genius [ INACTIVE ] - avatar
+ 1
file:///storage/emulated/0/Your/Path/To/Directory
24th Jul 2020, 11:49 AM
Arnesh
Arnesh - avatar
+ 1
I clicked on the html file i wanna open then it opened in chrome and the link was: content://0@media/external/file/15698 Really strange... 🤔🤔🤔
24th Jul 2020, 11:53 AM
MSN
MSN - avatar
+ 1
So how to fix it? I mean the method u gave may work but how can i find the path to my file? long pressing the file and clicking details gave the file location but the location is different from what u said...
24th Jul 2020, 11:56 AM
MSN
MSN - avatar
+ 1
Ok I'll try
24th Jul 2020, 12:00 PM
MSN
MSN - avatar
+ 1
No MemeLord Dev u didn't misunderstood it.
25th Jul 2020, 7:54 AM
MSN
MSN - avatar
0
chrome
24th Jul 2020, 11:43 AM
MD Abdullah
MD Abdullah - avatar