X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Trying to show the meta description (https://forum.x-cart.com/showthread.php?t=21795)

kg 05-15-2006 07:09 AM

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

balinor 05-15-2006 07:15 AM

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!

kg 05-15-2006 07:20 AM

updated

TelaFirma 05-15-2006 08:59 AM

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.

kg 05-15-2006 09:18 AM

Got it! Thanks!


All times are GMT -8. The time now is 05:25 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.