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

Different product description tpl's according to category?

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 12-04-2003, 03:56 PM
 
jordan0 jordan0 is offline
 

Advanced Member
  
Join Date: Oct 2003
Location: San Francisco, CA
Posts: 77
 

Default Different product description tpl's according to category?

Hi,
I'm fairly new to X-cart Б─⌠ I've been setting up my first store for a few weeks now. The store carries a pretty diverse inventory and I would like to be able to customize the "product description" template to provide different options for certain categories of products.

For example:
One of our categories is jewelry chain, bought by the foot. I would like to simply change the words "Quantity" and "Items" to "Footage" and "Feet" on the descriptions that come up for the products in the "chain" category. I would also like to stick "per foot" after the "Price: $ 1.50".

I hope I explained that well enough. Should I be trying to alter templates to accomplish this or is this a Smarty/PHP type of job? I'm guessing that I will have to modify some php file to make it check which category it is listing and load a .tpl file accordingly.

Any help is appreciated. I would at least like to know which php scripts and/or templates I need to look at.

Thanks!
- Jordan
Reply With Quote
  #2  
Old 12-05-2003, 02:33 PM
 
jordan0 jordan0 is offline
 

Advanced Member
  
Join Date: Oct 2003
Location: San Francisco, CA
Posts: 77
 

Default More info...

After reading a bit more on the subject of mods, I've narrowed my approach further:

Ideally, I would like to add a new option to the "Add new product" form in the admin area. This would be implemented in the form of radio buttons for "Sold by weight" "Sold by length" and "Sold by item". "Sold by item" would be the default and choosing it would allow x-cart to add the product as it normally does. Accompanying the other two choices would be a menu allowing the admin to select a unit measurement such as "feet" "yards" or "pounds" etc.

When one of these new options is used, a handfull of alternate language variables for the product info templates will have to be used (and some minor changes to the templates made as well) to make the "details" reflect the changes. ie, "Quantity available" would have to be "Length available" and "per foot" would be inserted after the price...

Even I can see that this mod is a pretty major job. What i would like to know is just how hard will this be? I am operating on a pretty tight budget so I can't afford to hire someone to do it Б─⌠ but I am willing to invest a lot of time to learn to do it myself. If there is an existing mod like this for sale at a decent price, though, I would certainly buy it!
Any / all advice is welcomed. It would be awesome if someone could tell me what files to examine or give me some pointers regarding the ordering system. I just don't know where to start!

Thanks,
Jordan
Reply With Quote
  #3  
Old 12-07-2003, 03:19 PM
 
jordan0 jordan0 is offline
 

Advanced Member
  
Join Date: Oct 2003
Location: San Francisco, CA
Posts: 77
 

Default ok i give up

I'm having a hell of a time getting anywhere with this mod. I have no experience with PHP or smarty for that matter...
If someone wants to give me a quote for this job I will certainly consider it. thanks.
Reply With Quote
  #4  
Old 12-09-2003, 09:06 PM
 
jordan0 jordan0 is offline
 

Advanced Member
  
Join Date: Oct 2003
Location: San Francisco, CA
Posts: 77
 

Default This thread helped to answer my quesiton...

maybe this will help someone out in the future...
http://forum.x-cart.com/viewtopic.php?t=1015
__________________
Jordan Sitkin
http://www.kitkraft.biz
X-Cart 4.0.18 [unix]
Reply With Quote
  #5  
Old 12-09-2003, 10:37 PM
  B00MER's Avatar 
B00MER B00MER is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Keller, TX (Cart-Lab.com)
Posts: 3,165
 

Default

Code:
{if $cat eq "3"}{$product.param03}{else}{$products.desc}{/if}

Something as simple as above would work and just use the product extra fields for the alternate descriptions
__________________
Cart-Lab - 100+ Social Bookmarks for X-Cart.
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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:12 PM.

   

 
X-Cart forums © 2001-2020