500 Internal Server Error: This is a general error message that can occur for a variety of reasons. To fix it, you can try increasing the PHP memory limit, deactivating plugins, and checking for a .htaccess file issue.404 Page Not Found Error: This error occurs when a user tries to access a page that does not exist. To fix it, you can check for broken links, ensure your permalinks are set correctly, and update your…

The following query returns information about the URL containing cipla-product.html Query the URL’s information Request: { urlResolver(url: “cipla-product.html”) { entity_uid relative_url redirectCode type } } Response: { “data”: { “urlResolver”: { “entity_uid”: “MQ==”, “relative_url”: “joust-duffle-bag.html”, “redirectCode”: 0, “type”: “PRODUCT” } } }

$urlInterface = \Magento\Framework\App\ObjectManager::getInstance() ->get(\Magento\Framework\UrlInterface::class); $currentUrl = $urlInterface->getCurrentUrl(); Example: private $urlInterface; public function __construct( … \Magento\Framework\UrlInterface $urlInterface … ) { $this->urlInterface = $urlInterface; } public function getCurrentUrl() { return $this->urlInterface->getCurrentUrl(); }

In order to add 301 redirect in Magento 2 take the following steps: 1. Go to Admin Panel > Marketing > SEO& Search > URL Rewrites. Magento 2 301 Redirect 2. Then press the Add URL Rewrite button. (Add URL Rewrite) 3. Enter URL Rewrite Information Choose “Custom” in the Create URL Rewrite select box. Choose the store view pesklevu the URL Rewrite to be added to in the Store field. Set the path you…