Area username attribute

Definition and usage

username Attribute sets or returns href attribute value The username part.

href The attribute specifies the destination of the link within the specified area.

In the URL, the username part is the username entered by the user. It is specified after the protocol and before the password part.

Example: https://billgates:bill234@www.example.com (billgates is the username, bill234 is the password).

Tip:Use password attribute Set or return href attribute value The password part.

Example

Example 1

Return the URL part of the specific area in the image map:

var x = document.getElementById("venus").username;

Try it yourself

Example 2

Change the username part of the specific area in the image map:

document.getElementById("venus").username = "newUsername";

Try it yourself

Syntax

Return username property:

areaObject.username

set username property:

areaObject.username = username

অ্যাট্রিবিউট মান

মান বর্ণনা
username ইউআরএল-এর ব্যবহারকারীর অংশ নির্ধারণ

প্রযুক্তিগত বিবরণ

ফলাফল: স্ট্রিং মান, ইউআরএল-এর ব্যবহারকারীর অংশকে প্রতিনিধিত্ব করে

ব্রাউজার সমর্থন

চ্রোম এজ ফায়ারফক্স স্যাফারি ওপেরা
চ্রোম এজ ফায়ারফক্স স্যাফারি ওপেরা
সমর্থিত অসমর্থিত সমর্থিত অসমর্থিত সমর্থিত