VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: slammy on August 22, 2012, 21:57:29 PM

Title: how to display manufacturer products under manufacturer details page
Post by: slammy on August 22, 2012, 21:57:29 PM
Hi VM-Community,

I was wondering if anybody of you knows a solution how to show products which belongs to a certain manufacturer directly under that manufacturer details page without a second click?

Background:
I don´t want to create own manufacturer categories and place the products in it, because this leads to more than one url per product what is bad for SEO, besides the page navigation with prev and next links cannot work correctly than anymore ... (http://forum.virtuemart.net/index.php?topic=101208.msg337330#msg337330).

Situation now:
If I use the button "show all products from this manufacturer" on the manufacturer details page, it leads to a generated site with joomla config standard keys and descriptions and no describing mf-text and mf-logo

Why to change this?:
I think it would be really fine for some SEO reasons to do that, because the combination of important keywords and information in manufacturer description texts, manufacturer logo with alt-text and meta keys, generell meta keys and descriptions (if you assign a joomla menue entry to the virtuemart manufacturer details page it´s possible to set up metadata! - ok finally it does not work with jml 2.5.6, but you can put some manual edited keys and descriptions to view.html.php in components/com_virtuemart/view/manufacturer/view.html.php), H1 paragraph and finally a lot of productlinks maybe named with the manufacturer leads to good seo results for this manufacturer-brand.

In my case, we generated a good portion of traffic about the manufacturer names, maybe because there aren´t this famous as others ...
Does anybody is in the same boat with me? Would appreciate any help or idea

greetz slammy

sr vm 2.0.8_e and jml2.5.6
Title: Re: how to display manufacturer products under manufacturer details page
Post by: kobm on September 20, 2012, 11:40:31 AM
Hi

Have you solved this issue, cause i have the same problem.

i have searched forum for 3 houres now, but no solution.

Købmanden
Title: Re: how to display manufacturer products under manufacturer details page
Post by: slammy on September 20, 2012, 21:08:40 PM
Hi,

I am afraid I didn´t solve this issue yet. I was wondering why there are so less pp replying to this treat. Maybe there is a lack of people who try to generate traffic over the brandnames, I don´t know.
If I will find an answer by myself next time, I post it for sure!

regards slammy
Title: Re: how to display manufacturer products under manufacturer details page
Post by: kobm on September 21, 2012, 12:10:06 PM
Ok. Thanks for info

We must hope that some one, makes a solotion, cause it looks realy bad, with that button.

Købmanden
Title: Re: how to display manufacturer products under manufacturer details page
Post by: joely666 on September 27, 2012, 17:27:30 PM
I'm not sure if this will help you, but it works for my requirements.
I needed to bypass the manufacturer details page and go straight to a list of manufacturers
products, but include the relevant manufacturer-description and image at the top of the page.
I have already set the VM configuration to hide categories in the product browse pages.


In components/com_virtuemart/views/category/view.html.php
Under the line (182 for me)
$virtuemart_manufacturer_id = JRequest::getInt('virtuemart_manufacturer_id',0 );

insert the following
// get manufacturer models
$model = VmModel::getModel('manufacturer');
if ($virtuemart_manufacturer_id !=0 ) {

$manufacturer = $model->getManufacturer();
$model->addImages($manufacturer,1);

$manufacturerImage = $manufacturer->images[0]->displayMediaThumb('class="manufacturer-image"',false);

$this->assignRef('manufacturerImage', $manufacturerImage);
$this->assignRef('manufacturer', $manufacturer);
$pathway->addItem(strip_tags($manufacturer->mf_name));
}


Then to get your manufacturer links to go directly to the page:
In components/com_virtuemart/views/manufacturer/tmpl/default.php

replace:
index.php?option=com_virtuemart&view=manufacturer&virtuemart_manufacturer_id=
with:
index.php?option=com_virtuemart&view=category&virtuemart_manufacturer_id=

and make the same change twice in /modules/mod_virtuemart_manufacturer/tmpl/default.php
(as mentioned in https://forum.virtuemart.net/index.php?topic=101528.0)

There are still a couple of issues with this. I can't see how to get rid of the 'view all products' link.
It's not components/com_virtuemart/views/manufacturer/tmpl/details.php. For now I've hidden it with css, which is probably
frowned upon!

Also I don't know if there is any way to override view.html.php.

But I hope it's useful to someone anyway.
Title: Re: how to display manufacturer products under manufacturer details page
Post by: kobm on September 28, 2012, 21:03:57 PM
Hi Thanks
but i is not working

the manufacturer-description and image at the top of the page is not showing
only the products.
is there something else to do ?

Jan
Title: Re: how to display manufacturer products under manufacturer details page
Post by: spyderwebdesign on September 28, 2012, 21:09:27 PM
Is this what you are trying to do?

Click the manufacture's name from the left nav.

www.likdancewear.com
Title: Re: how to display manufacturer products under manufacturer details page
Post by: kobm on September 28, 2012, 21:29:16 PM
Hi

something like that, but i want the Manufacturer
description and images on top of the page

Jan
Title: Re: how to display manufacturer products under manufacturer details page
Post by: slammy on September 29, 2012, 14:05:42 PM
Hi,

thanks joely666 for your solution. I did not have the time to test it yet. I will make this test next weekend and post my finals. I will post too how to get rid of the "show all items" button. I found this place earlier and I made some changes with it. I think it was at view.html.php, but I am not sure yet. SOrry I don´t have the time now to have a look at it. I´ll post next weekend.
regards slammy
Title: Re: how to display manufacturer products under manufacturer details page
Post by: mdalabar on January 29, 2013, 21:44:07 PM
I don't need manufacturer info so i do this and display products while clicking on manufacturer names
This works for me
replace this line in mod_virtuemart_manufacturer/tmpl/default.php (instead of core file editing do overriding)
$link = JROUTE::_('index.php?option=com_virtuemart&view=manufacturer&virtuemart_manufactur_id=' . $manufacturer->virtuemart_manufacturer_id);
with
$link = JROUTE::_('index.php?option=com_virtuemart&view=category&virtuemart_manufacturer_id=' . $manufacturer->virtuemart_manufacturer_id);
Title: Re: how to display manufacturer products under manufacturer details page
Post by: Dreams on April 16, 2013, 12:20:13 PM
Anyone solved this?
Title: Re: how to display manufacturer products under manufacturer details page
Post by: balai on April 16, 2013, 12:52:54 PM
Just use the custom filters module.
Its in the free version
http://breakdesigns.net/extensions/custom-filters
Title: Re: how to display manufacturer products under manufacturer details page
Post by: zainabubu on June 04, 2013, 02:02:32 AM
I have the pro version of custom filters and still want manufacturers listed with products once it gets clicked on from product details page. It'd simplify things a whole lot for people clicking through the website. the less unnecessary clicks the better.
Title: Re: how to display manufacturer products under manufacturer details page
Post by: balai on June 04, 2013, 09:31:57 AM
Hi

Custom Filters display the products that belong to a manufacturer, when a manufacturer is selected in the cf module, but it has no any effect in the product details pages.

To solve that you should change the manufacturer link in the product details page.
components\com_virtuemart\views\productdetails\tmpl\default_manufacturer.php
Title: Re: how to display manufacturer products under manufacturer details page
Post by: zainabubu on June 05, 2013, 09:18:52 AM
how so?

thanks
Title: Re: how to display manufacturer products under manufacturer details page
Post by: dros1a on July 06, 2016, 16:49:29 PM
i have read so many threads by people asking the same question but still haven't found a way to change this behavior i would really like some help...

Just like the other people i can't figure out how can i display products under manufacturer description in the manufacturer page

I am using Virtuemart  3.0.2 - 3.0.16

I tried this but it's not working in my version
http://forum.virtuemart.net/index.php?topic=106733.0

i guess if i find a way to make this change i will understand how templating and virtuemart files are working.
Title: Re: how to display manufacturer products under manufacturer details page
Post by: Krx on August 23, 2017, 18:28:27 PM
Hello

I'd like to know how to get the same behavior.

When some Manufacturer is selected, to have all their products listed below manufacturer description,
with pagination and sorting, like what happens when specific category is clicked.

I tried to use custom filters pro but without luck - money wasted.
Custom filters pro is also in conflict with WM ajax or something, when searching with it,
when selecting product children instead of ajax change it opens new window.

If searching with VM provided solution, ajax works OK.

Regards
Title: Re: how to display manufacturer products under manufacturer details page
Post by: Krx on August 23, 2017, 19:12:47 PM
Hello

After some digging and testing,
I managed to solve it by overriding /components/com_virtuemart/views/manufacturer/tmpl/details.php file
and using this component: https://www.regularlabs.com/extensions/componentsanywhere

In my override file, below code for description I added this:

{component index.php?option=com_virtuemart&view=category&virtuemart_manufacturer_id=<?php echo $this->manufacturer->virtuemart_manufacturer_id ?>}

I also removed code for displaying button

And now, when in manufacturer details, all their products are shown below, without need to click a button.

If someone needs it I can add more detailed instructions.

HTH
Regards
Title: Re: how to display manufacturer products under manufacturer details page
Post by: David on September 09, 2017, 00:51:03 AM
IMO the simplest way is to override modules\mod_virtuemart_manufacturer\tmpl\default.php and replace the line

$link = JROUTE::_('index.php?option=com_virtuemart&view=manufacturer&virtuemart_manufacturer_id=' . $manufacturer->virtuemart_manufacturer_id);
with
$link = JROUTE::_('index.php?option=com_virtuemart&view=category&virtuemart_manufacturer_id=' . $manufacturer->virtuemart_manufacturer_id);

Of course, this skips manufacturer's details altogether and only displays products of that manufacturer.
Title: Re: how to display manufacturer products under manufacturer details page
Post by: MKI-Miro on September 08, 2018, 12:50:03 PM
How to change this parameter is joomla menu item ?
Title: Re: how to display manufacturer products under manufacturer details page
Post by: GJC Web Design on September 08, 2018, 15:34:34 PM
see your other post 

https://forum.virtuemart.net/index.php?topic=140879.msg495794#msg495794