Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1734)

Unified Diff: content/test/data/download/download-attribute.html

Issue 246893006: [Downloads] Clear suggested filename on cross origin redirect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/test/data/download/download-attribute.html
diff --git a/content/test/data/download/download-attribute.html b/content/test/data/download/download-attribute.html
new file mode 100644
index 0000000000000000000000000000000000000000..4fd070db96e3bf8942b6113de2229b9053f32077
--- /dev/null
+++ b/content/test/data/download/download-attribute.html
@@ -0,0 +1,12 @@
+<!DOCTYPE html>
+<html>
+<body>
+<a download="suggested-filename" href="">link</a>
+<script>
+ var anchorElement = document.querySelector('a[download]');
+ url = window.location.href;
+ anchorElement.href = url.substr(url.indexOf('=') + 1);
+ anchorElement.click();
+</script>
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698