Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: pages/adware.md

Issue 29350056: Issue 4348 - control adware page warning through url parameter (Closed)
Patch Set: Created Aug. 22, 2016, 3:36 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pages/adware.md
===================================================================
--- a/pages/adware.md
+++ b/pages/adware.md
@@ -31,6 +31,7 @@
.warning
{
+ display: none;
color: #e11a2c;
}
@@ -42,6 +43,11 @@
background-color: #fff;
}
+ .show-warning .warning
+ {
+ display: block;
+ }
+
.icon-header
{
vertical-align: middle;
@@ -131,6 +137,14 @@
color: #e11a2c;
}
</style>
+
+ <script type="text/javascript">
+ document.addEventListener("DOMContentLoaded", function()
+ {
+ if (window.location.search.indexOf("warning=true") == 1)
+ document.body.className = "show-warning";
juliandoucette 2016/09/22 14:25:10 This is destructive. I would recommend using += "
saroyanm 2016/09/22 14:57:45 You are totally right, done.
+ }, false);
+ </script>
</head>
# {{page-header I’m using <fix>Adblock Plus</fix> but I still see suspicious ads}}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld