Address bar shows current url if you want to access in javascript program then we use window.location.href
Syntax
1 | window.location.href |
Example:
1 | alert("My current URL is "+window.location.href ); |
Address bar shows current url if you want to access in javascript program then we use window.location.href
Syntax
1 | window.location.href |
Example:
1 | alert("My current URL is "+window.location.href ); |