How can I detect if the target link will trigger download, before user actually clicks it?
For example, the following link is a file:
string url="http://www.orimi.com/pdf-test.pdf"
But this one is not:
string url="https://www.google.com/"
I tried like:
Uri uri = new Uri(url);
if (uri.IsFile)
//...
but it's gives false
for the pdf link