How to get file name and url file when clicked in browser to download

I want to get the file name and url file when clicked to download it from an Android browser. I tried to use the method when you click "download" in the show file name and url file, but it does not show them correctly.

Display example

How can I get it right?

+4
source share
1 answer

I use this code to get url in the application and solving my problem

Uri data = getIntent().getData(); if (data != null) { String url = data.toString(); edtlink.setText(url); } 
+3
source

All Articles