We’re rewarding the question askers & reputations are being recalculated! Read more.

Hot answers tagged

23

In Magento admin, when editing a product go to the tab design and add the following to custom layout: <reference name="head"> <action method="setRobots"><meta>NOINDEX,NOFOLLOW</meta></action> </reference>


18

you can observe the event controller_action_layout_generate_blocks_after like this: public function setRobots($observer) { $controller = $observer->getAction(); $fullActionName = $controller->getFullActionName(); if ($fullActionName == 'catalog_product_view') { //if on product page $product = Mage::registry('product'); //...


18

You can configure the option by following below path in Magento 2.x admin. Stores -> Configuration -> General (Left side) -> Design (section) -> Search Engine Robots -> Default Robots (Select)-> Select INDEX, FOLLOW NOINDEX, FOLLOW INDEX, NOFOLLOW NOINDEX, NOFOLLOW Save the configuration as you need. You can configure this option by [...


17

There was a survey conducted at one point on twitter (and maybe other channels) By Elena Leonova asking the community if they use certain modules from Magento 1. After this survey, the decision was taken to not port the tags and polls modules to Magento 2 because there was not much use of them. But I'm almost sure someone from the community will implement ...


14

I have fix this problem by this thread Step 1: Goto Home page in the CMS page editor Step 2: click on design, then enter this XML into the “Layout Update XML” field: <reference name="head"> <action method="setData"><key>title</key><value>Home</value></action> </reference> Now the home page title is set ...


11

The meta data is different from page to page. For example, in the product page the meta data comes from the Meta title, Meta description and Meta keywords attributes of the products you are viewing. The same goes for categories and CMS pages. These values can be set from the layout file for any page like this: <page_handle_here> <reference name=...


11

It sounds like a behavior which can happen if you do not have the ".htaccess" file by Magento or if the ".htaccess" file is messed up. Please try adding or replacing the current file with the default ".htaccess" file from Magento.


10

The table is core_config_data Search the path column for web/seo/use_rewrites Change the value column to 0 Clear your Magento cache so the config table gets re-read.


8

For the temporary solution I would suggest you the following step to perform Go to System ->Configuration On left hand side select General -> Web and under that you will find the Search Engines Optimization tab Use Web Server Rewrites => No I think your server does not having rewrite_module enable please check whether it is enabled or not. Also check that ...


8

I just had to do the same and decided to just add a plugin after the getKeywords Method of the page config which returns an empty string. works great di.xml: <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd"> <type ...


8

___from_store is used somehow to determine the url rewrite of the current page. Let's me give an example. You have 2 store views. EN and FR. In EN you have the url product.pthml. In FR you have the same product respond to produit.phtml. When you are on the EN store view on product.phtml and you switch the language you are going go to product.phtml?...


7

Writing robots.txt is tricky. Robots defines the architecture of your website for crawlers. Normally i use the following robots for my website # Website Sitemap Sitemap: www.example.com/sitemap.xml User-agent: Googlebot-Image Disallow: / Allow: /media/catalog/product/ # Crawlers Setup User-agent: * # Directories User-agent: * Disallow: /app/ Disallow: /...


7

You can add the following to your .htaccess file to enable it: <ifModule mod_headers.c> Header add Strict-Transport-Security "max-age=84600; includeSubDomains" </IfModule>


6

I believe you are looking for canonical links. If you go to your admin panel and navigate to system -> Configuration -> Catalog In the Search Engine Optimisation tab, you can find the following two entries: Use Canonical Link Meta Tag For Categories Use Canonical Link Meta Tag For Products This will not delete the redundant pages, but will add the same ...


6

I know this is quite old, but I'd like to share my solution anyway as it doesn't override/clone any core files. In your custom module add the following to your config.xml: <config> ... <frontend> <events> <catalog_controller_product_init> <observers> <...


5

If There is a CMS page then go to the CMS >> Page >> Add/ edit you find the META tab in that you can add Keywords and Description. and title will come form Page Information >> Page Title. If you load the product then This will load from the Catalog >> Manage Products >> you find in Meta Information Tab in that. Magento Load this data Dynamically. Hope you ...


5

First I would login to the Webmaster Tools with Google and you can specify parameters for it to ignore like you're experiencing with some URLs. Site Configuration -> URL Parameters I would also make sure you are submitting sitemap.xml properly to Google and other Search engines to help ensure things are crawled properly. Robots.txt docs: https://...


5

This most likely is a file ownership issue. You probably upload the Magento files as another user and the web server user can't access the files. You have to change ownership so the webserver user owns the files. First, you need to find out what user your webserver runs under. If your running Ubuntu, it's usually www-data. In that case, you simply go to ...


5

Try with following code: $store = Mage::app()->getStore(); $path = Mage::getResourceModel('core/url_rewrite') ->getRequestPathByIdPath('product/456', $store); $url = $store->getBaseUrl($store::URL_TYPE_WEB) . $path; Just replace 456 with your product id.


5

In default rwd theme the breadcrumbs are coming on product details page. Check at Template file: Basically magento calls the breadcrumb in root template files 1column.phtml, 2columns-left.phtml etc. using the code <?php echo $this->getChildHtml('breadcrumbs') ?> . Check at page.xml And on page.xml it defines the breadcrumb block. You need to ...


5

Go to System > Configuration > Design > Html Head their you can see "Title Suffix" you can give your title - Example.com here which will add in all the page at last For More Information check http://magento-online-tutorials.blogspot.in/2015/11/adding-suffix-or-prefix-to-title-tag-in.html


5

At the end after all that dynamic JS and loading you get correct valid HTML code which can be crawled by Google and there is no any real difference to Magento 1 or any other CMS. Future more Google increase algorithms every day and they trying to catch all JS same as end user see it, so even if with full page cache some parts will be loaded dynamically - ...


5

I have to agree with you that this is minimally not 'good' for SEO. Magento has to make sure that inline JS is made to a bare minimun. That this is inline JS is just lazy programming. We put this JS in a separate js file. To do this follow these instructions: Go to a random page and find (chrome: right click > view source) the JS with this var: var ...


5

To me you can simply create the following files in your module: view/frontend/layout/catalogsearch_advanced_result.xml view/frontend/layout/catalogsearch_result_index.xml In case of a theme, the file locations will be different, under your theme folder: Magento_CatalogSearch/layout/catalogsearch_advanced_result.xml Magento_CatalogSearch/layout/...


5

I ended up in using the below solution. I saw it is a quite common configuration for multi-language Magento websites. This solution provides a default language with a redirect from "normal" url (urls without lang subfolder) to urls with the default lang subfolder. For example, if it is the default language, it happen this: example.com/ --> ...


5

You can do this by updating category Layout Update XML in admin. Admin - > Products -> Categories -> Select the category -> Design -> Layout Update XML -> Add the below code -> Save <head> <meta name="robots" content="NOINDEX,NOFOLLOW"/> </head> Remove cache and check. You can see the changes in front end product category page ...


4

After much thought and research I've settled on the meta tag in System > Config > Design > Miscellaneous Head Scripts method for the following reasons: It allows me to set a new verification for multiple websites, even by store view (handy for subdomained translations, e.g. en.mystore.com) Prevents files from being created on a production site, ...


4

The quick easy solution is to setup your robots.txt to ignore the parent path: ## Do not crawl seach pages and not-SEO optimized catalog links Disallow: /catalogsearch/ Disallow: /catalog/product_compare/ Disallow: /catalog/category/view/ Disallow: /catalog/product/view/ Snippet from: http://turnkeye.com/blog/optimize-robots-txt-for-magento/ Alternate ...


4

Disclaimer: I'm not an SEO expert I have worked with a number of companies who have many analysts on staff who worry about this every day. In my experience the rules around use of H tags is always shifting. Here are the current "rules" (according to Google) as I understand them: You determine the priority of your own content. There is no hard-and-fast rule ...


4

What you want can't be achieved - afaik. The problem is, that magento is planned with "product in many categories". The problem now is magento doesn't prefer any category and instead it shows no category at all. The categories are used, when you click throught the categories, this is the only place (afaik) where the category rewrites are used. But I think ...


Only top voted, non community-wiki answers of a minimum length are eligible