downloading only the header of a file
-
01-10-2019 - |
문제
I'm using mechanize for scraping a website which works nicely, however since you can't tell from a link what kind of file it is linking to e.g. http://somesite.com/images.php?get=123 is it possible to download only the header only?
It doesn't have to use mechanize but is there any Rails way of doing this?
올바른 솔루션이 없습니다
다른 팁
Mechanize has the headers available after downloading a file. page.header['xxx']
or file.header['xxx']
.
제휴하지 않습니다 StackOverflow