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

Side by Side Diff: chrome/browser/resources/safe_browsing_multiple_threat_block.html

Issue 10694037: Add a policy to disable proceeding through the Safe Browsing interstitials. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fixed <button>/jstemplate Created 8 years, 5 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 unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <title i18n-content="title"></title> 4 <title i18n-content="title"></title>
5 <style> 5 <style>
6 body { 6 body {
7 background-color:#500; 7 background-color:#500;
8 font-family:Helvetica,Arial,sans-serif; 8 font-family:Helvetica,Arial,sans-serif;
9 margin:0px; 9 margin:0px;
10 } 10 }
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 <script> 80 <script>
81 function agreed(form) { 81 function agreed(form) {
82 form.continue_button.disabled = !form.continue_button.disabled; 82 form.continue_button.disabled = !form.continue_button.disabled;
83 } 83 }
84 84
85 function sendCommand(command) { 85 function sendCommand(command) {
86 window.domAutomationController.setAutomationId(1); 86 window.domAutomationController.setAutomationId(1);
87 window.domAutomationController.send(command); 87 window.domAutomationController.send(command);
88 } 88 }
89 89
90 function showDiagnostic(errorID) {
91 sendCommand("showDiagnostic:" + errorID);
92 }
93
94 function reportError(errorID) {
95 sendCommand("reportError:" + errorID);
96 }
97
98 function learnMore() { 90 function learnMore() {
99 sendCommand("learnMore"); 91 sendCommand('learnMore');
100 } 92 }
101 93
102 function proceed() { 94 function proceed() {
103 sendCommand("proceed"); 95 sendCommand('proceed');
104 } 96 }
105 97
106 function takeMeBack() { 98 function takeMeBack() {
107 sendCommand("takeMeBack"); 99 sendCommand('takeMeBack');
100 }
101
102 function showOrReport() {
James Hawkins 2012/07/02 15:56:06 nit: Document method.
Joao da Silva 2012/07/03 13:39:52 Done.
103 var id = this.getAttribute('chromiumID');
104 var isMalware = this.getAttribute('chromiumIsMalware');
105 var cmd = isMalware ? 'showDiagnostic:' : 'reportError:';
106 sendCommand(cmd + id);
107 return false;
James Hawkins 2012/07/02 15:56:06 Why are you returning any value?
Joao da Silva 2012/07/03 13:39:52 Again, this isn't my code. Returning false from an
108 } 108 }
109 </script> 109 </script>
110 </head> 110 </head>
111 111
112 <body oncontextmenu="return false;"> 112 <body oncontextmenu="return false;">
113 <div class="background"><img src="ssl_roadblock_background.png" width="100%" hei ght="100%" alt="background" onmousedown="return false;"/></div> 113 <div class="background"><img src="ssl_roadblock_background.png" width="100%"
James Hawkins 2012/07/02 15:56:06 Newlines for <img> and </div>.
Joao da Silva 2012/07/03 13:39:52 Done.
114 height="100%" alt="background" onmousedown="return false;"/></div>
114 <table width="100%" cellspacing="0" cellpadding="0"> 115 <table width="100%" cellspacing="0" cellpadding="0">
115 <td class="cell" valign="middle" align="center"> 116 <td class="cell" valign="middle" align="center">
116 <div class="box"> 117 <div class="box">
117 <div class="icon"><img src="shared/images/phishing_icon.png" alt="Malware Icon" onmousedown="return false;"/></div> 118 <div class="icon"><img src="shared/images/phishing_icon.png"
119 alt="Malware Icon" onmousedown="return false;"/></div>
118 <div class="title" i18n-content="headLine"></div> 120 <div class="title" i18n-content="headLine"></div>
119 <div class="main" i18n-values=".innerHTML:description1"></div> 121 <div class="main" i18n-values=".innerHTML:description1"></div>
120 <div class="main" i18n-content="description2"></div> 122 <div class="main" i18n-content="description2"></div>
121 <div class="main" id="template_root"> 123 <div class="main" id="template_root">
122 <table cellpadding="5" jsvalues="$counter:{value: 0}"> 124 <table cellpadding="5" jsvalues="$counter:{value: 0}">
123 <tr jsselect="errors" class="errorlist"> 125 <tr jsselect="errors" class="errorlist">
124 <td jscontent="typeLabel"></td> 126 <td jscontent="typeLabel"></td>
125 <td jscontent="url"></td> 127 <td jscontent="url"></td>
126 <td><a href="" onclick="var id= this.getAttribute('chromiumID'); thi s.getAttribute('chromiumIsMalware') ? showDiagnostic(id) : reportError(id); retu rn false;" jscontent="errorLink" jsvalues="chromiumID:$counter.value;chromiumIsM alware:type=='malware'" jseval="$counter.value++"></a></td> 128 <td><a href="" onclick="showOrReport()"
129 jsvalues="chromiumID:$counter.value;chromiumIsMalware:type=='mal ware'"
130 jscontent="errorLink" jseval="$counter.value++"></a></td>
127 </tr> 131 </tr>
128 </table> 132 </table>
129 </div> 133 </div>
130 134
131 <div class="main"><a href="" i18n-content="description3" onclick="learnMor e(); return false;" onmousedown="return false;"></a></div> 135 <div class="main"><a href="" i18n-content="description3"
136 onclick="learnMore(); return false;"
137 onmousedown="return false;"></a></div>
132 <div class="main"> 138 <div class="main">
133 <form class="submission"> 139 <form class="submission">
134 <input name="checky" id="checky" type="checkbox" onclick="agreed(this. form)">&nbsp;<label for="checky" i18n-content="confirm_text"></label> 140 <input name="checky" id="checky" type="checkbox"
135 <input type="button" name="continue_button" i18n-values="value:continu e_button" disabled="true" onclick="proceed();"><br> 141 jsdisplay="!proceedDisabled"
136 <input type="button" name="back_button" i18n-values="value:back_button " onclick="takeMeBack()"> 142 onclick="agreed(this.form)">&nbsp;
143 <label for="checky" i18n-content="confirm_text"
144 jsdisplay="!proceedDisabled"></label>
145 <button name="continue_button" i18n-content="continue_button"
146 disabled="true" jsdisplay="!proceedDisabled"
147 onclick="proceed();"></button><br>
148 <button name="back_button" i18n-content="back_button"
149 onclick="takeMeBack()"></button>
137 </form> 150 </form>
138 </div> 151 </div>
139 </div> 152 </div>
140 </td> 153 </td>
141 </table> 154 </table>
142 </body> 155 </body>
143 </html> 156 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698