mod_virtuemart_category_lis

Before you ask about IDnR Addon see the VirtueMart - Invoice, Delivery Note and Receipt Addon
patrex
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Mar 2009, 21:45

mod_virtuemart_category_lis

Post by patrex »

This is actually a very nice addon. But I have stumble up on a little problem.

I only want to show the head categorys, not sub cats and deeper. Is it any one who knows if this is possible to do?

Kind regards

Patric
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: mod_virtuemart_category_lis

Post by Jan »

Hi, this addon only display head (main) categories)

Jan
If you find Phoca extensions useful, please support the project
patrex
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 16 Mar 2009, 21:45

Re: mod_virtuemart_category_lis

Post by patrex »

Real strange, since it list some 152 categories.

Perhaps i have made some thing wrong?

In our shop we have :12 Main categories _| 1
under this their is sub cats _| 2

But the Category list shows also my sub categories wich makes the list far to long to have on the frontpage :D
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: mod_virtuemart_category_lis

Post by Jan »

Then this added needs to be customized, with some recursive function to load all the categories :-(
If you find Phoca extensions useful, please support the project
stefanos
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 03 Nov 2009, 05:54

Re: mod_virtuemart_category_lis

Post by stefanos »

very nice module, but I got 2 needs maybe you could help.

1. I have a problem styling with css. Using the category thumbnails ON, the category name is on the right of the thumb and I need it below. Maybe there is no way to do this though and need to hack the code but I am not a php expert.

2. I would like the thumbnail to be a link to the category too (same as it's name). That surely is a php hack. If someone can help ?

I think the area to hack is this:

Code: Select all

echo '<td>'. ps_product::image_tag( $categories[$kp]["category_thumb_image"], "alt=\"".$categories[$kp]["category_name"]."\"", 0, "category") . '</td>';
	} else if ($displayImg == 1) {
		echo '<td>'. JHTML::_('image', 'modules/mod_virtuemart_category_list/assets/images/icon-folder-small.png', $categories[$kp]['category_name']). '</td>';
	}
	echo '<td align="left" valign="middle" ><a href="'. $sess->url( URL .'index.php?page=shop.browse&category_id=' . $categories[$kp]['category_child_id']). '">'.$categories[$kp]['category_name'].'</a></td>';
I will really appreciate any soft of help, even to point me to the right directions in how to hack the code.
Thanks
Joomla 1.5.14 & VirtueMart 1.1.3
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: mod_virtuemart_category_lis

Post by Jan »

Hi, yes you need to change it in the code

1) just paste the <br /> (in html), .'<br />'. in php) after the name so it will displayed below or set padding top to the category name

2) if the image is an image you can close it to link '<a href...>'. ... link .'</a>' if this is a css background it cannot be used as link.

Jan
If you find Phoca extensions useful, please support the project
stefanos
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 03 Nov 2009, 05:54

Re: mod_virtuemart_category_lis

Post by stefanos »

Hi, thanks Jan for your help,
just because I tried those things and all I was getting was errors.. :) could you show me where to put the .'<br />'. and where in the code to start the <a href=" from ?

cheers
Joomla 1.5.14 & VirtueMart 1.1.3
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: mod_virtuemart_category_lis

Post by Jan »

Hi, check the version 1.0.1 and see the parameters:

https://www.phoca.cz/download/category/2 ... ist-module

Jan
If you find Phoca extensions useful, please support the project
stefanos
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 03 Nov 2009, 05:54

Re: mod_virtuemart_category_lis

Post by stefanos »

thanks for the update and last version, will check it out as soon as possible !!
thanks!
Joomla 1.5.14 & VirtueMart 1.1.3
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48689
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: mod_virtuemart_category_lis

Post by Jan »

OK
If you find Phoca extensions useful, please support the project
Post Reply