Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Two groups of categories? Is this possible?

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 06-16-2008, 02:38 AM
 
sparrowdog sparrowdog is offline
 

eXpert
  
Join Date: Jan 2007
Posts: 244
 

Default Two groups of categories? Is this possible?

I have a potential client who will be selling swimwear. For the categories, we want the following structure.

BRAND 1
> print a
> print b
> print c
BRAND 2
> print 1
> print 2
> print 3
BRAND 3
> style 1
> style 2
BRAND 4
> style a
> style b
Bikini Tops
Bikini Bottoms
One Piece
Chlorine Resitant
Sarongs

I would like a clear definintion between where the BRAND 4 and it's sub-catgories ends, and where Bikini Tops starts.

Is this possible? With a mod?
__________________
Version 4.1.6 to 4.1.11
Reply With Quote
  #2  
Old 06-16-2008, 09:49 AM
  rkdiddy's Avatar 
rkdiddy rkdiddy is offline
 

Advanced Member
  
Join Date: Mar 2005
Posts: 60
 

Default Re: Two groups of categories? Is this possible?

What you need to do is create another categories.tpl file - categories2.tpl. You can then call to both of them in your home.tpl.

In the categories.tpl file you will need to add a line:
Quote:
{if $c.order_by gt 100 and $c.order_by lt 200}

And, in categories2.tpl file you will need to add a line:
Quote:
{if $c.order_by gt 201 and $c.order_by lt 300}

Then in the Admin area ID your categories in these ranges. It will place each category to the appropriate menu.
__________________
Stealth Cords - Discrete Power Cords for Automotive Enthusiasts
www.stealthcords.com
X-Cart version: 4.1.9
Reply With Quote
  #3  
Old 06-16-2008, 01:50 PM
 
sparrowdog sparrowdog is offline
 

eXpert
  
Join Date: Jan 2007
Posts: 244
 

Default Re: Two groups of categories? Is this possible?

Wow, didn't think it would be that simple. Thanks for that!
__________________
Version 4.1.6 to 4.1.11
Reply With Quote
  #4  
Old 07-29-2008, 10:21 PM
 
sparrowdog sparrowdog is offline
 

eXpert
  
Join Date: Jan 2007
Posts: 244
 

Default Re: Two groups of categories? Is this possible?

I tried this and it didn't work. I have tried it with and without a closing {/if} tag in various positions in the categories.tpl file and I keep getting the complete list.

Is there any further information you can give me?
__________________
Version 4.1.6 to 4.1.11
Reply With Quote
  #5  
Old 08-03-2008, 11:38 PM
 
Asiaplay Asiaplay is offline
 

X-Wizard
  
Join Date: Oct 2005
Posts: 1,242
 

Default Re: Two groups of categories? Is this possible?

You will need a closing {/if} for sure.

Perhaps a silly question / idea... have you checked your category "categoryid" code numbers, that are actually kept in the SQL database for each category (for example all mine fall into the 200-300 range)...
Note: these can only be seen when viewing the SQL table via something like phpMyAdmin
So just wondering if you perhaps have not change the ranges to be correct for the "category id" code number actually used in your own store?

Cheers - Asiaplay
__________________
X-Cart Gold version 4.1.9
(plus built in X-Cart bugs!)
Reply With Quote
  #6  
Old 08-04-2008, 12:22 AM
 
sparrowdog sparrowdog is offline
 

eXpert
  
Join Date: Jan 2007
Posts: 244
 

Default Re: Two groups of categories? Is this possible?

I changed all my category ID's and it still didn't work.

I'll just pay x-cart for the mod. No big deal. Thanks for the suggestion though.
__________________
Version 4.1.6 to 4.1.11
Reply With Quote
  #7  
Old 08-10-2008, 11:02 AM
 
Richard Walkling Richard Walkling is offline
 

Member
  
Join Date: Apr 2004
Posts: 22
 

Default Re: Two groups of categories? Is this possible?

There is a free mod from BCSengineering that lets you put page breaks in the category listings - if you use that and adapt the code to put your headings instead of a break it will work.

http://www.bcsengineering.com/store/catalog/Group_Categories_for_Better_Viewing__FREE_Xcart_Mo d-p-62.html
__________________
Richard
4.7.12
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 11:23 AM.

   

 
X-Cart forums © 2001-2020