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

Help asked for product listing small modification

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 04-09-2006, 01:41 AM
 
mlowrey mlowrey is offline
 

Member
  
Join Date: Mar 2005
Posts: 28
 

Default Help asked for product listing small modification

Hello, i would like to change my product listing please take a look at the pictures, one now, and one of how i want it.

Can someone explain me howto do this ? THX

THis is the situation now:

http://www.projectieland.nl/images/normal.JPG

And this is how i would like it to have !:

http://www.projectieland.nl/images/new.JPG[/img]
__________________
4.0.16 stable and testing 4.10 rc4 - ALL THE QUESTIONS ARE FOR 4.1
Reply With Quote
  #2  
Old 04-09-2006, 01:46 AM
  NightFire's Avatar 
NightFire NightFire is offline
 

X-Adept
  
Join Date: Jul 2004
Location: The Netherlands
Posts: 561
 

Default

You can easily do this by editing the product.tpl file.
You can modify the whole layout.

for example you can make a table. 50% for the left, 50% for the right. The put the product information in the left table, and the buttons, price etc in the right table. Make sure you don't mess up with the {if} tags or you'll get some smarty errors.

For the listings of the products you need to edit the products.tpl and products_t.tpl

Hope it helps.
__________________
Best regards,
Niki Buitenrust Hettema

X-Cart Gold 4.1.8 (Live & Loaded)
Royal Bhaktapur: Handmade products from Nepal - Pashmina's, scarfs, shawls, stola's and more...
Reply With Quote
  #3  
Old 04-09-2006, 01:50 AM
 
mlowrey mlowrey is offline
 

Member
  
Join Date: Mar 2005
Posts: 28
 

Default

yes i know, but i have to make a new table and that is were is goes wrong.

I hoped that someone could explein it to me. I thought that there would be more people intresting in this mod. Or that there was already a post with something similar.

I have tryed many things but it is getting a mess.

If someone can help that would begreat.
__________________
4.0.16 stable and testing 4.10 rc4 - ALL THE QUESTIONS ARE FOR 4.1
Reply With Quote
  #4  
Old 04-09-2006, 04:38 AM
  TelaFirma's Avatar 
TelaFirma TelaFirma is offline
 

X-Adept
  
Join Date: Nov 2002
Location: North Carolina USA
Posts: 930
 

Default

Edit /customer/main/products.tpl and find the lines:

Code:
{$products[product].descr|truncate:300:"...":true} </FONT> <HR size="1" noshade width="100%" align="left">

Remove the line
Code:
<HR size="1" noshade width="100%" align="left">
and insert this in its place:

Code:
</td><td>
Reply With Quote
  #5  
Old 04-09-2006, 06:09 AM
 
mlowrey mlowrey is offline
 

Member
  
Join Date: Mar 2005
Posts: 28
 

Default

This is mine products.tp from customer/main/
Can someone help me. thx When i thought i had it, the search function in the admin didden't worked anymore.


{* $Id: products.tpl,v 1.72 2006/03/28 08:21:07 max Exp $ *}
{if $active_modules.Feature_Comparison ne '' && $products && $printable ne 'Y'}
{include file="modules/Feature_Comparison/compare_selected_button.tpl"}
{include file="modules/Feature_Comparison/products_check_js.tpl"}
{/if}
{if $usertype eq "C" and $config.Appearance.products_per_row ne "" and $config.Appearance.products_per_row gt 0 and $config.Appearance.products_per_row lt 4 and ($featured eq "Y" or $config.Appearance.featured_only_multicolumn eq "N")}
{include file="customer/main/products_t.tpl" products=$products}
{else}
{if $products}
{section name=product loop=$products}
{assign var="discount" value=0}
<table width="100%">
<tr>
<td class="PListImgBox">
{include file="product_thumbnail.tpl" productid=$products[product].productid image_x=$config.Appearance.thumbnail_width product=$products[product].product tmbn_url=$products[product].tmbn_url}
{if $active_modules.Special_Offers ne "" and $products[product].have_offers}
{include file="modules/Special_Offers/customer/product_offer_thumb.tpl" product=$products[product]}
{/if}


{$lng.lbl_see_details}
{if $active_modules.Feature_Comparison ne '' && $products[product].fclassid > 0 && $printable ne 'Y'}




{include file="modules/Feature_Comparison/compare_checkbox.tpl" id=$products[product].productid}
{/if}
</td>
<td valign="top">
<font class="ProductTitle">{$products[product].product}</font>
{if $config.Appearance.display_productcode_in_list eq "Y" and $products[product].productcode ne ""}


{$lng.lbl_sku}: {$products[product].productcode}
{/if}
<font size="1">




{$products[product].descr|truncate:300:"...":true}


</font>
<hr class="PListLine" size="1" />
{if $products[product].product_type eq "C"}
{include file="buttons/details.tpl" href="product.php?productid=`$products[product].productid`&amp;cat=`$cat`&amp;page=`$navigation_p age`"}
{else}
{if $active_modules.Subscriptions ne "" and ($products[product].catalogprice gt 0 or $products[product].sub_priceplan gt 0)}
{include file="modules/Subscriptions/subscription_info_inlist.tpl"}
{else}
{if $products[product].taxed_price ne 0}
{if $products[product].list_price gt 0 and $products[product].taxed_price lt $products[product].list_price}
{math equation="100-(price/lprice)*100" price=$products[product].taxed_price lprice=$products[product].list_price format="%3.0f" assign=discount}
{if $discount gt 0}
<font class="MarketPrice">{$lng.lbl_market_price}: <s>
{include file="currency.tpl" value=$products[product].list_price}
</s></font>

{/if}
{/if}
{if $active_modules.Special_Offers ne "" and $products[product].use_special_price ne ""}
<s>
{/if}
<font class="ProductPrice">{$lng.lbl_our_price}: {include file="currency.tpl" value=$products[product].taxed_price}</font><font class="MarketPrice">{include file="customer/main/alter_currency_value.tpl" alter_currency_value=$products[product].taxed_price}</font>{if $discount gt 0}{if $config.General.alter_currency_symbol ne ""},{/if} {$lng.lbl_save_price} {$discount}%{/if}
{if $active_modules.Special_Offers ne "" and $products[product].use_special_price ne ""}
</s>
{/if}
{if $products[product].taxes}


<div class="PListTaxBox">{include file="customer/main/taxed_price.tpl" taxes=$products[product].taxes}</div>
{/if}
{if $active_modules.Special_Offers ne "" and $products[product].use_special_price ne ""}
{include file="modules/Special_Offers/customer/product_special_price.tpl" product=$products[product]}
{/if}
{else}
<font class="ProductPrice">{$lng.lbl_enter_your_price}</font>
{/if}
{/if}
{if $usertype eq "C" and $config.Appearance.buynow_button_enabled eq "Y"}
{include file="customer/main/buy_now.tpl" product=$products[product]}
{/if}
{/if}
</td>
</tr>
</table>






{/section}
{if $active_modules.Feature_Comparison ne '' && $products && $printable ne 'Y'}
{include file="modules/Feature_Comparison/compare_selected_button.tpl" no_form=true}
{/if}
{else}
{$lng.txt_no_products_found}
{/if}
{/if}
__________________
4.0.16 stable and testing 4.10 rc4 - ALL THE QUESTIONS ARE FOR 4.1
Reply With Quote
  #6  
Old 04-09-2006, 08:44 AM
  TelaFirma's Avatar 
TelaFirma TelaFirma is offline
 

X-Adept
  
Join Date: Nov 2002
Location: North Carolina USA
Posts: 930
 

Default

Same as before:

Change
Code:
{$products[product].descr|truncate:300:"...":true} </font> <hr class="PListLine" size="1" />

to

Code:
{$products[product].descr|truncate:300:"...":true} </font> </td> <td>
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 12:28 PM.

   

 
X-Cart forums © 2001-2020