How is it possible that Magento create SEO Links for products ONLY WITH the category - magento

The problem:
Magento creates 2 SEO Links for a product like this:
product/1695/60 category/category2/productname catalog/product/view/id/1695/category/60
and for the same product:
product/1695 productname catalog/product/view/id/1695
the first is a link with the category, and the second is without but only with the productname.
But what I want is that magento creates only ONE Seo Link in fact this link WITH the category, and not this link without the category.
The question:
How is it possible that Magento create SEO Links for products ONLY WITH the category?
I search in the admin menu and the only thing what I find is the option "use categorypath for article urls". But if I choose "YES" in this option And I rebuild the indexes I got 2 SEO Link for my article.. one without the category, and one with the categorypath.
Can somebody help me?
Thanks!

Yes, it is a common problem with Magento. You do have 2 options to create the result you want:
(harder one), you truncate table core_url_rewrite and reindex
database with "use category path to product urls" set to no. If this
is a live site you will have to create a redirect tool to point users
to correct pages. I recommend the extension I've created
https://github.com/SnowdogApps/Snowdog_Error404toolsm, it is for
redirects :-)
use this extension https://amasty.com/magento-unique-product-url.html , easy to install and get the job done

Related

How to create different URLs for items in a drop down list on a product page?

I am not a coder, and I am working for a company involved in e-commerce activities, so please help me!
Currently we are looking to merge two different aspects of the business, where we will have the other company arms website detailing the product variations (i.e. Product A in sizes 1, 2, 3 and 4) on their page as separate enteries as part of their mission driven section, which link directly to our product page.
The issue we have is, on our website we have a drop down menu, and what we want to achieve is for the when the visitor selects the buy on the product page for Product A in Size 2 it links directly to our ecommerce page with a pre filled in drop down menu for that exact product selection.
Does anyone know how we could achieve this in Magento? Could this be done in custom URLs?
Thanks in advance!!
To preselect a simple product in a configurable product, the address of a simple product should look like this for example:
/mona-pullover-hoodlie.html#143=167&93=53
where /mona-pullover-hoodlie.html - configurable product URL,
143, 93 - attributes IDs,
167, 53 - option IDs.
In order to change the URL of simple products, you can create a Plugin (Interceptor) for Magento\Catalog\Model\Product::getProductUrl(), where to generate the URL as in the example above.
I made VCT Simple Product URL module on Magento Marketplace that solves this problem.

Magento 2 URL Rewrites

I have recently moved my store over to Magento 2. The store is up and running and all is good. I've just noticed that for most products, Magento 2 has created 3 different URL's for the same product.
If for instance, the product is located in Category A > Sub Category B. The following URL's are created;
mystore.com/product.html,
mystore.com/categorya/product.html,
mystore.com/categorya/subcategoryb/product.html
I think this will end up being a problem for search engines, as its going to result in a fair bit of duplicate content.
Ideally I'd like to just keep the;
mystore.com/categorya/subcategoryb/product.html
url, how can I stop Magento from rewriting the other 2 urls, whilst making sure links still work from all pages.
It's worth mentioning, that if I visit the product from a home page link, it uses the mystore.com/product.html url. Whilst if I visit the product from the Category A page, it uses the mystore.com/categorya/product.html url. Similar if I click a link in the subcategory.
you can use default magento settings by stores->configuration -> Search Engine Optimization -> Use Categories Path for Product URLs -> 'yes'
If this can solve your problem

How to solve duplicate content issues in Magento?

On magento Site that i am working on certain products have minor changes in the product setup, except the product description.How do i solve the duplicate content issue without creating variable product?
Canonicalization may be your best bet. This tells search engines which version of the page you want to be indexed.
For example:
If you have /productCategory/product001 as well as /newProducts/product001 you would want to add <link rel=”canonical” href=”http://www.domain.com/productCategory/product001”> to the new product page to tell search engines to give all ranking authority to the new product page to the actual page for that product.
This product will still rank, you're just going to be showing users the product under its category rather than the product under the new products page.

Why is my wish list limited to one item?

Im using magento 1.9 and im having an issue with the wishlist, for some reason it will only let me have one item in my wishlist and when I goto add another item to the wishlist it replaces the item that was already in my wishlist, there is nothing in the configuration to limit the wishlist item im just a bit confused at why it would be doing this, any ideas ?
Right!!, after hunting the web to try and find a solution I have found a solution, you have to edit the file app/code/core/Mage/Wishlist/Model/Wishlist.php
find:
public function getItemCollection()
and change
$this->_itemCollection = Mage::getResourceModel('wishlist/item_collection')
->addWishlistFilter($this)
->addStoreFilter($this->getSharedStoreIds($currentWebsiteOnly))
->setVisibilityFilter();
to
$this->_itemCollection = Mage::getResourceModel('wishlist/item_collection')
->addWishlistFilter($this)
->addStoreFilter($this->getSharedStoreIds($currentWebsiteOnly));
this worked for me and im using magento 1.9.0.1
the source for this fix is here: http://www.magentocommerce.com/boards/viewthread/291225/
This is an out of the box feature, you do not need to edit any core code to fix this. Correction: You don’t have to edit any code
I had the same issue and found it was from an improper import of products and that website availability was incorrectly set.
It seems that Magento added a website filter on the wishlist collection to prevent items not available in a website from appearing in a customer's wishlist.
It also seems that items may not have a website value => which prevents wish list items from appearing (or just 1 item, the last one added).
How to fix it : Simply select your store products on catalog page, select ‘Update Attributes’ action and click on submit.
Select Websites panel and check your website in ‘Add Product To Websites’ block.
Reindex your data if necessary.
You can now add your products to your wishlist and see all of them in your wishlist. This is the proper solution and does not remove functionality from your Magento webstore.
Simply reindex everything in: System > Index management

Magento 2 stores with different product url

Here is my situation, my company buy product with no brand and sell them in its own brand.
We have 2 websites and 2 brands, some products exist in both of our brand with different name.
Example : product A of brand A named BrandA Product Premium and the same product on the other site is named BrandB Product Super.
But on both website the url-key is the same (the name of the product in the default view) so on site1 I have :
http://www.site1.com/brand-a-product-premium.html that is very good.
On site2 I have http://www.site2.com/brand-a-product-premium.html If you type in the correct url : http://www.site2.com/brand-b-product-super.html you are redirected to the bad url.
I can correct this by creating a custom url_rewrite, but there are thousands of product in this case, so I may have done something wrong and there should be a better solution for this.
May I have some help ?
Best regards.
If you are using one instance of Magento in a multistore setup you can override the url key as well as any other product attribute for each store view. Select the store view for site 2 from the dropdown on the left hand side of the edit product page and then override the required fields for that store view.
I have a multistore site where I sell some products on both but not all and using the above method gives me full control over every aspect of the same product for each store view. e.g. Custom name, description, images, categories etc. To ensure that a product is not shown on a particular site via catalog or search, I disable that product in that store view by setting visibility to none.
Do not use the URL rewrite option this will come back to haunt you!

Resources