Open Bug 832707 Opened 11 years ago Updated 2 years ago

"Save As" for a Web Page Uses Page's Title, Should Use File Name From URI

Categories

(Toolkit :: General, defect)

x86
Windows XP
defect

Tracking

()

People

(Reporter: david, Unassigned)

References

()

Details

Mozilla/5.0 (Windows NT 5.1; rv:18.0) Gecko/20100101 SeaMonkey/2.15

This was initially reported in the mozilla.support.seamonkey newsgroup in message <news://news.mozilla.org:119/t5idnbPFIt5OZGfNnZ2dnUVZ_sudnZ2d@mozilla.org> with the Subject: "2.15. Save Page As. filename".  From that report, this is something introduced with SeaMonkey 2.15.  

1.  Use SeaMonkey to view the page at the cited URI.  This page has the title element "* Here ** there % be $ tigers *".  

2.  On the menu bar, select [File > Save Page As].  

3.  On the Save As window, navigate to where you want to save the Web page in HTML format WITHOUT changing the file name.  

4.  Outside of SeaMonkey, navigate to where the file was saved.  

The URI says the file name is Save_as.html.  In Windows, the resulting file name is <Here   there % be $ tigers.htm>.  This is almost the same as the page's title element except all asterisks have been removed, leaving blank spaces where embedded asterisks appeared.  Also, it was saved as an .htm file when the original was an .html file.  This can make locating the saved file difficult, especially if the user chooses to use a search tool on the URI file name or on the expected .html file extension.
You are essentially requesting the opposite of the recently-landed bug #254139.
Re comment #1:  Yes I am.  At least, there should be a preference to allow users the option of choosing either the actual file name from the URI or the title element.  The default should reflect how other downloads occur -- using the file name.  (Or are there plans to change the file names of other files downloaded by SeaMonkey?)  

Note that the SaveAsFilename extension cited at <https://bugzilla.mozilla.org/show_bug.cgi?id=254139#c71> is only for Firefox and is not compatible with SeaMonkey.  

I have updated my test page to include a comma and an at (@) symbol in the title element.
Try this, simple change, just adding an install section for SeaMonkey:

http://www.filesplat.com/.therube/shared/O72QQ685A7FMBUO3EC3PUQCQFC7170I1----SaveAsFilename-MOD.4.SM.xpi
I will try the extension.  However, I consider extensions like this to be temporary work-arounds for actually fixing bugs.  

By the way, if I place my cursor over <http://rossde.com/test/Save_as.html> without actually viewing that Web page, right click, and select Save Link Target As from the pull-down context menu, it saves the file using the URI file name, not the title element.
Re comment #3:

I downloaded and installed the SaveAsFilename-MOD.4.SM.xpi extension.  While it installed okay, it did not work.  Doing a Save Page As still used the Web page's title element for the file name.
Using file name instead of page title was one of the most annoying things in Gecko-based browsers for years. While I don't mind about pref for that, there must be no turn back to old behavior.
Annoying is not getting a choice.

All three candidates (last regular part of the url, page title, content-disposition) have their disadvantages ('index.php', 'Main Page', intentional nonsense to make it harder to save files), so not only should it be configurable, but also possible to configure it to see and choose from the three candidates each time.

BUT, isn't this an upstream (Gecko) problem instead of SeaMonkey?
It is an upstream problem, indeed, you can try to convert the add-on above with Converter from http://forums.mozillazine.org/viewtopic.php?f=40&t=2834855, or wait for decision from module owner
Component: Download & File Handling → General
Product: SeaMonkey → Toolkit
Version: unspecified → Trunk
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.