Chrome "Save-As" feature does not properly handle pages loaded via AJAX
Reported by
tomac...@gmail.com,
Jun 4 2016
|
|||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.102 Safari/537.36 Steps to reproduce the problem: 1. Goto any website that is generated via JavaScript (ie. not static content) 2. Attempt to save the file 3. Now view the file What is the expected behavior? The "Save As" should have similar output to the page as it initially appeared What went wrong? Browser's implementation of the "Save As" feature predates the introduction of Dynamic JavaScript Applications. At that time, the page did not change, and so returning the server output was acceptable. Now, the DOM Document is changing, and the application should save the present state of the document, as does the "Print" button and "Save As" in regular document editors. Given that the latest HTML code is always visible in the inspector, this should not be difficult. Did this work before? No Chrome version: 50.0.2661.102 Channel: stable OS Version: OS X 10.11.1 Flash Version: I saved a webpage yesterday, hoping to store the info, but when I went to view it, it was garbage. Now, I have to print everything to PDF.
,
Jun 10 2016
tomac120@ - can you clarify which save page flavor you've used? Chromium supports 3 flavors of saved pages: 1. Webpage, HTML Only 2. Webpage, Complete (= foo.html file + foo_files directory with other resources) 3. Webpage, Single File (= MHTML, to see this option one might have to use --save-page-as-mhtml flag, because this option is by default only present on ChromeOS AFAIR). AFAIK, flavor #1 by design saves the original content (without content dynamically generated by javascript) and flavors #2 and #3 should support dynamically generated content. If the repro above uses #1, then everything is WAI and the issue should be closed as WontFix. If the repro above uses #2 or #3, then I'd love to hear more details (i.e. get a specific webpage where things are broken).
,
Jun 10 2016
Thanks, I did not know about that. I tried "Complete" and it worked properly. I might suggest slightly more explicit names, but my problem is fixed. On Mac there is no single file option, btw.
,
Jun 10 2016
As for explicit naming, "Webpage Source, HTML Only" would make that clear.
,
Jun 11 2016
Or "Webpage, HTML Source Only".
,
Jun 11 2016
Thank you for providing more feedback. Adding requester "lukasza@chromium.org" for another review and adding "Needs-Review" label for tracking. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jun 13 2016
ainslie@, could you please take a look? My apologies for assigning a random bug - I hope that you can route this bug to the appropriate UI/UX person. Would it make sense to consider tweaking the UI strings here? AFAIU the confusion here was whether "Webpage, HTML Only" would include 1) only the original, static HTML content VS 2) dynamically generated HTML content. Description of save flavors: - "Webpage, HTML Only" saves only the original, static HTML content (without any modifications) - "Webpage, Complete" saves the current HTML content which includes content dynamically generated by javascript (this save flavour also slightly alters the HTML content so that links refer to locally saved files). - "Webpage, Single File" - this behaves like "Webpage, Complete", but puts all the html and subresources into a single MHTML file. Current IDS_SAVE_PAGE_DESC_HTML_ONLY string + various alternatives (proposed in #c4 and #c5 above + some ideas from me): - Current string: "Webpage, HTML Only" - Alternative: "Webpage, HTML Source Only" - Alternative: "Webpage, Original HTML Only" <- my vote / proposal :-) BTW: I am not sure if we are constrained wrt the length of the UI string. I guess not, because Save-Page-As is not exposed on mobile devices AFACT. OTOH, maybe the file dialog dropdowns have some limitations on the various platforms we support? FWIW, I've checked on Windows and AFACT the "Webpage, Complete" is the default option, so I guess one could argue that a user has to go out of their way to pick a different save flavor.
,
Jun 13 2016
As far as the comment that "user has to go out of their way to pick a different save flavor", I would add I chose "HTML Only" to store in a single file and because I did not need the images. I wasn't aware that a dynamic option even existed and the terminology "HTML Only" vs. "Complete" does not make clear any difference except the storage of resources locally. Strictly speaking, it is not a choice of "format" but a timeline (saving the current state of the document vs. saving the document before it was loaded).
,
Jun 20 2016
I'm probably not the right person. talo@ is thinking much more about saving pages in general right now so might have better ideas.
,
Feb 6 2017
,
Mar 13 2017
Cleaning up sheriffbot label "Needs-Review" label as a part of modified "Needs-Feedback" sheriffbot rule. [ref bug for cleanup 684919]
,
Jul 2 2017
Same happens with form POSTs. If you fill in the form here (you don't need real data, first name and project is all that's needed): https://www.freebsd.org/cgi/monthly.cgi Hit Download XML the XML will be rendered. Now right click and choose "Save As". The resulting file will contain the HTML of the form and not rendered output of the form POST. Lost work due to this bug :(
,
Jul 2 2017
We actually found that this works find when using "Complete" option and were just discussing naming conventions. Not sure how that works for POST.
,
Jul 2 2017
The complete option is not available for XML, so I'd suggest another ticket for that.
,
Jul 3
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Aug 3
This bug has an owner, thus, it's been triaged. Changing status to "assigned". |
|||||||||
►
Sign in to add a comment |
|||||||||
Comment 1 by patricia...@chromium.org
, Jun 6 2016Labels: OS-Android OS-Chrome OS-Linux OS-Windows