如何防止信用卡号字段被浏览器缓存

发布于 2024-08-30 07:05:47 字数 73 浏览 0 评论 0原文

我的网页上有一个包含信用卡号的输入字段。防止浏览器缓存该值的最佳方法是什么?

任何解决方案都需要在多种浏览器上运行。

I have an input field on a webpage that contains a credit-card number. What is the best way of preventing the browser from caching this value?

Any solution needs to work on a large selection of browsers.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

一袭水袖舞倾城 2024-09-06 07:05:47

将属性 autocomplete="off" 添加到您的 html 表单中。例如,

<form name="form1" id="form1" method="post" autocomplete="off"
  action="http://www.example.com/form.cgi">
[...]
</form>

请参阅此页面

Put attribute autocomplete="off" to your html form. E.g.

<form name="form1" id="form1" method="post" autocomplete="off"
  action="http://www.example.com/form.cgi">
[...]
</form>

See this page.

此生挚爱伱 2024-09-06 07:05:47
<asp:TextBox Runat="server" ID="Textbox1" autocomplete="off"></asp:TextBox>
<asp:TextBox Runat="server" ID="Textbox1" autocomplete="off"></asp:TextBox>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文