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

Trying to show the meta description

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 05-15-2006, 07:09 AM
 
kg kg is offline
 

Member
  
Join Date: Mar 2006
Posts: 23
 

Default Trying to show the meta description

Hi All,
I've got these categories and icons associated at the bottom of my home page (http://mtrhomefurnishings.com/xcart/home.php). I would like to have the field meta_descr print below the headings. The file I'm working in is categories_features.tpl in the cusomer directory. This is what I have now:
{* $Id: categories.tpl,v 1.23 2004/06/24 09:53:29 max Exp $ *}
{capture name=mycategories}
<hr class="content_divider">
<div id="featured_cats">
<ul class="featured_cats">
{foreach name="featuredcats" from=$subcategories item="cat"}
<li {strip}
{if $smarty.foreach.featuredcats.iteration%4 == 0}
style="clear: left;"
{/if}
>
{/strip}
<div class="cat_spot">
<a href="home.php?cat={$cat.categoryid}">
[img]{$xcart_web_dir}/icon.php?categoryid={$cat.categoryid}[/img]
</a>
<h2>{$cat.category}</h2>


{$cat.meta_descr} </p>
</div>

{/foreach}[/list]<hr class="content_divider">
</div>
{/capture}
{include file="dialog.tpl" title="Categories" content=$smarty.capture.mycategories extra="" class="mycatlist" no_title="1"}

It shows the category headings and the images associated, just not the meta description. How can I make it do this? Thanks
__________________
xCart Gold Version 4.0.16
Reply With Quote
  #2  
Old 05-15-2006, 07:15 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Please put your X-Cart version in your signature, we can't help you without it. Edit profile, enter version, enter help desk password, click the 'Always attach my signature:' box, save. Thanks!
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 05-15-2006, 07:20 AM
 
kg kg is offline
 

Member
  
Join Date: Mar 2006
Posts: 23
 

Default

updated
__________________
xCart Gold Version 4.0.16
Reply With Quote
  #4  
Old 05-15-2006, 08:59 AM
  TelaFirma's Avatar 
TelaFirma TelaFirma is offline
 

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

Default

meta_descr is not part of the $subcategories array. The only items in that array are:

Code:
[categoryid] => [parentid] => [categoryid_path] => [category] => [product_count] => [avail] => [order_by] => [subcategory_count] => [is_icon] => [image_path] => [category_path] =>

So, in order to show that you would need to change the queries in /include/categories.php that build the $subcategories array.
Reply With Quote
  #5  
Old 05-15-2006, 09:18 AM
 
kg kg is offline
 

Member
  
Join Date: Mar 2006
Posts: 23
 

Default

Got it! Thanks!
__________________
xCart Gold Version 4.0.16
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 05:31 AM.

   

 
X-Cart forums © 2001-2020