Web Analytics

Fill the form & Get Installation Support





    How to get category by url key in Magento 2?

    Here is the code for getting category by category URL key.

    The module name is: Magemonkeys_Categorydata

    Create a block file: Categoryurl.php

    Now you can get category by using this function getCategory($urlKey) in your phtml file

    You can get an array of category data.

     

    Fill the below form if you have any Magento programming need.





      Recent Articles

      Author Info

      Author Image

      Magento 2 Developer

      Hire P. Garchar

      Get a Free Quote





        Connect With Us