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

Adding new categy box on left side

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #11  
Old 02-09-2006, 01:06 AM
 
vixnfox vixnfox is offline
 

Advanced Member
  
Join Date: Feb 2006
Location: Adelaide, South Australia
Posts: 82
 

Default Re New Category Box

Hi, I thought this question would answer my search, but no....

I want to actually add a menu to the Left Side. I Have Categories, Special, and Help by default. I want to add another menu for FAQs to have information on various product components. Can I do this???

vixnfox
__________________
V 4.3.1 Live:

Developing on
PHP 5.3.0
MySQL server 5.0.75-community-log
MySQL client 5.1.36
Web server Apache/2.2.11 (Unix) mod_ssl/2.2.11
Windows 7 64bit on a Toshiba Satellite P500

ADELAIDE, SOUTH AUSTRALIA
Reply With Quote
  #12  
Old 02-09-2006, 03:06 AM
 
balinor balinor is offline
 

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

Default

If you want to add a new menu, try these steps:

1. Copy one of the existing menus (special.tpl is an easy one) and create a new template.

2. Remove the code for the 'special' link in the new template, and add your own links.

3. Add the menu to customer/home.tpl (just copy the way special.tpl is called and change the name).

Done!
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #13  
Old 02-09-2006, 11:00 AM
 
Glowinafuse Glowinafuse is offline
 

Advanced Member
  
Join Date: Dec 2005
Posts: 80
 

Default

okay, I have been to that thread with no luck so far... And I really need to figure this out so I can continue with making the shop look better

here is my code for the subcategories.tpl

please help please!!! I have not found out how to do it...

Code:
{* $Id: subcategories.tpl,v 1.29 2002/11/26 14:55:13 alfiya Exp $ *} {if $active_modules.Bestsellers ne "" and $config.Modules.bestsellers_menu ne "Y"} {include file="modules/Bestsellers/bestsellers.tpl"} {/if} { include file="customer/main/navigation.tpl" } {if ($navigation_page eq "")||($navigation_page eq "1")}{$current_category.description|regex_replace:"/[\n]/":" "} {/if} {capture name=dialog} {assign var="tmp" value="0"} {section name=cat_num loop=$subcategories} {if $subcategories[cat_num].category}{assign var="tmp" value="1"}{/if} {/section} {section name=cat_num loop=$subcategories} { if %cat_num.first% } <table border=0 cellspacing=5 width=100%> {/if} {if $smarty.section.cat_num.index is div by 2} </tr><tr valign="top"> {/if} <td valign="top" width="70" align="center"> <a class="alt" href="home.php?cat={ $subcategories[cat_num].categoryid }"> [img]icon.php?categoryid={$subcategories[cat_num].categoryid}[/img] </a> </td> <td align=center><a class="alt" href="home.php?cat={ $subcategories[cat_num].categoryid }"> {$subcategories[cat_num].category|escape}</a> { $subcategories[cat_num].description|escape } {if $config.Appearance.count_products eq "Y"} <font class=Text> {if $subcategories[cat_num].product_count} { $subcategories[cat_num].product_count } {$lng.lbl_products} {elseif $subcategories[cat_num].subcategory_count} { $subcategories[cat_num].subcategory_count } {$lng.lbl_categories|lower} {/if} </font> {/if} </td> { if %cat_num.last% } </tr></table> {/if} {/section} {if $tmp and $products ne "" } <br clear=_all>{*<hr size=1 noshade>*} {/if} {if $products eq "" and $tmp eq "0"} {$lng.txt_no_products_in_cat} {/if} {include file="customer/main/products.tpl" products=$products} {/capture} {include file="dialog.tpl" title=$current_category.category|regex_replace:"/.*\//":"" content=$smarty.capture.dialog extra="width=100%"} {if $products eq ""} {if $f_products ne ""} {include file="customer/main/featured.tpl"} {/if} {/if} { include file="customer/main/navigation.tpl" }

thanks in advance for the help...
__________________
Gold 4.1.11
www.houseoftropicals.com/store
Reply With Quote
  #14  
Old 02-09-2006, 11:54 PM
 
vixnfox vixnfox is offline
 

Advanced Member
  
Join Date: Feb 2006
Location: Adelaide, South Australia
Posts: 82
 

Default

sorry to hijack your thread glow, just a thanks to Balinor (again!! what a man) for sorting my problem.

I am about to create a new menu. Taking balinors idea a little further, I just tracked the includes from home.php. After a while (cos I only had this thing a few days) you get the idea how the logic goes.
The key is in $smarty->assign("main", <your name>"; in home.php
home.php includes skin1/customer/home.tpl which itself includes home_main.tpl, and its here that the $smarty-> is switched,
{if $main eg "yourname" }
( include file ="customer/main/yourname.tpl" }
yourname.tpl of course is your stuff you want displayed.


A start is to duplicate the "special" menu.
In home.php, under the include special.tpl add
{include file="skin1/customer/yourname.tpl"}
duplicate special.tpl as yourname.tpl into skin1/customer

You now have 2 "special" menus. Replace the .tpls with your own.

Dont know if this helps you, but I felt good after I worked it out.

vixnfox
cheers from Oz
__________________
V 4.3.1 Live:

Developing on
PHP 5.3.0
MySQL server 5.0.75-community-log
MySQL client 5.1.36
Web server Apache/2.2.11 (Unix) mod_ssl/2.2.11
Windows 7 64bit on a Toshiba Satellite P500

ADELAIDE, SOUTH AUSTRALIA
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 08:19 AM.

   

 
X-Cart forums © 2001-2020