]> git.scottworley.com Git - voter/commitdiff
Tell browsers not to auto-complete
authorScott Worley <scottworley@scottworley.com>
Sat, 19 Nov 2022 09:44:07 +0000 (01:44 -0800)
committerScott Worley <scottworley@scottworley.com>
Sat, 19 Nov 2022 09:44:07 +0000 (01:44 -0800)
src/main.rs

index 920384e839a4fdd18c1e6b301ab9aaa4f69d3d95..98cfc35f008d829651acf1fa9089a706b5e9c281 100644 (file)
@@ -132,7 +132,7 @@ fn prompt_for_vote(dir: PathBuf, request: cgi::Request) -> Result<cgi::Response,
         std::iter::once(Ok(HTML_HEADER.to_owned()))
             .chain(std::io::BufReader::new(cfile).lines().map(|rc| {
                 rc.map(|c| {
-                    format!("<tr><td><input type=\"checkbox\" disabled></td><td>{c}</td></tr>")
+                    format!("<tr><td><input type=\"checkbox\" autocomplete=\"off\" disabled></td><td>{c}</td></tr>")
                 })
             }))
             .chain(std::iter::once(Ok(HTML_FOOTER.to_owned())))