假设我有一个字符串形式的密码:
$password = "thisisaplaintextpassword"
我怎样才能把它变成下面的样子?
$password = "************************"
我想通过电子邮件向用户发送他们的帐户详细信息,但不想发送整个内容。
Use 字符串重复 http://php.net/manual/en/function.str-repeat.php
$password = str_repeat("*", strlen($password));
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)