I have the following web address:
dls = "http://www.muellerindustries.com/uploads/pdf/UW SPD0114.xls"
I tried to download the file:
urllib2.urlopen(dls, "test.xls")
This made a file called "test.xls" but this is clearly an html file. If I opened the html file in firefox it opened an excel file, but if I opened the file in excel it was definitely not the excel file I was looking for.
If I have a web address like the one above, how do I make python download the excel file as an excel file?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…