Today we talk about WooCommerce get the current URL. In this tutorial, We focus on getting the current URL for example you need to match or check what is current URL of the category Url or product URL or any other page URL.
Let’s start with our example.
$currentUrl = home_url($_SERVER['REQUEST_URI']);