The HTMLHyperlinkElementUtils
.password
特性为
USVString
containing the password specified before the domain name.
If it is set without first setting the
username
property, it silently fails.
string = object.password; object.password = string;
// Let's <a id="myAnchor" href="https://anonymous:flabada@developer.mozilla.org/en-US/docs/HTMLHyperlinkElementUtils.username"> be in the document
var anchor = document.getElementByID("myAnchor");
var result = anchor.password; // Returns:'flabada'
| 规范 | 状态 | 注释 |
|---|---|---|
|
HTML 实时标准
The definition of 'HTMLHyperlinkElementUtils.password' in that specification. |
实时标准 | 初始定义。 |
| 桌面 | 移动 | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
password
|
Chrome
Yes
|
Edge 79 |
Firefox
26
|
IE No |
Opera
Yes
|
Safari Yes |
WebView Android
Yes
|
Chrome Android
Yes
|
Firefox Android
26
|
Opera Android
Yes
|
Safari iOS Yes |
Samsung Internet Android
Yes
|
完整支持
不支持
见实现注意事项。
HTMLHyperlinkElementUtils
mixin it belongs to.
HTMLHyperlinkElementUtils