getPageUrl
The getPageUrl function returns the complete URL of the current page, including the protocol (http/https), domain, port, path, and query parameters. This URL is retrieved from the window.location.href property.
Works in: HTML5, React JS
Usage
Example: Get Current Page URL
const currentUrl = nfsfu234FormValidation.getPageUrl();
console.log(currentUrl); // Outputs the current page URLSee also
Last updated on