1

使用Fiddler并且Live HTTP Headers我还试图找出Firefox如何知道文件的名称并将其显示在Save As dialog.There's a Content-Dispositionin headers which has no file name: Content-Disposition: attachmentwhich should be Content-Disposition: attachment; filename=.... 那么 Firefox 是如何知道文件名的呢?

示例网址:

http://download.cnet.com/Flock/3000-2356_4-75210908.html?tag=contentMain;contentBody

4

2 回答 2

2

该网站重定向到

http://software-files-l.cnet.com/s/software/11/57/77/21/FlockSetup_1_2_213_0_3PD.exe?e=1289760172&h=6a553713be5eede3474e961542ad7db8&lop=link&ptype=1901&ontid=2356&siteId=4&edId=3&spi=27176364f3c3621b51584f0aa2c67dc6&pid=11577721&psid=75210908&fileName=FlockSetup_1_2_213_0_3PD.exe

BURL 的文件名部分(在最后一个/和查询字符串之间)是FlockSetup_1_2_213_0_3PD.exe.

于 2010-11-14T12:43:39.273 回答
0

我的直接猜测是来自您正在下载的文件的 URL 的文件名部分。

例如:http://example.com/dir/file.ext作为file.ext文件名部分。

于 2010-11-14T12:42:40.813 回答