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

Adding an external link to catagories menu

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 03-12-2009, 04:31 PM
  sjb1218's Avatar 
sjb1218 sjb1218 is offline
 

Newbie
  
Join Date: May 2008
Posts: 7
 

Default Re: Adding an external link to catagories menu

Quote:
Originally Posted by balinor
Make an embedded static page, that way the customer will always stay in the cart and won't lose any data they have saved.

You can edit customer/categories.tpl to add a hard link to the static page.

I need some assistance here. If I make an embedded static page it will show up in the help menu, correct? Assuming that is correct and that is not the option that I want, would I create a new category and then edit the template so that it will link to an external page?
__________________
Sharon
X-cart 4.1.9
Reply With Quote
  #2  
Old 03-12-2009, 04:34 PM
 
balinor balinor is offline
 

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

Default Re: Adding an external link to catagories menu

Please be sure to look at the date of a thread you post in, that one was almost 4 years old

Yes, you can hard-code an external link in the help menu by editing help.tpl. If you create a new static page or category, those will automatically link to their respective pages, you can't change the link on them.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 03-12-2009, 04:43 PM
  sjb1218's Avatar 
sjb1218 sjb1218 is offline
 

Newbie
  
Join Date: May 2008
Posts: 7
 

Default Re: Adding an external link to catagories menu

Quote:
Originally Posted by balinor
Please be sure to look at the date of a thread you post in, that one was almost 4 years old

Yes, you can hard-code an external link in the help menu by editing help.tpl. If you create a new static page or category, those will automatically link to their respective pages, you can't change the link on them.

Yes, I noticed that is was old, but it described exactly what I needed so I thought I'd use it. But I think I've confused myself anyway. LOL! Here's what I'm trying to accomplish - I want to add a new category and have it link to an external page. I specifically want it in the categories menu and not the help menu. Is that possible at all?
__________________
Sharon
X-cart 4.1.9
Reply With Quote
  #4  
Old 03-12-2009, 04:45 PM
 
balinor balinor is offline
 

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

Default Re: Adding an external link to catagories menu

You can't do it by creating a new category, you need to hard-code a link in customer/categories.tpl.

<a href="http://www.yoursite.com" target="_blank">Link text</a>
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote

The following user thanks balinor for this useful post:
Papotchka (04-03-2009)
  #5  
Old 03-12-2009, 05:01 PM
  sjb1218's Avatar 
sjb1218 sjb1218 is offline
 

Newbie
  
Join Date: May 2008
Posts: 7
 

Default Re: Adding an external link to catagories menu

Quote:
Originally Posted by balinor
You can't do it by creating a new category, you need to hard-code a link in customer/categories.tpl.

<a href="http://www.yoursite.com" target="_blank">Link text</a>

So I would add the code that you provided at the end of all the code that is already there, replacing "yoursite.com" with the appropriate URL? And how do I get the title of the category to show up, do I replace "Link text" with whatever I want the category to be called?
__________________
Sharon
X-cart 4.1.9
Reply With Quote
  #6  
Old 03-12-2009, 05:36 PM
 
balinor balinor is offline
 

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

Default Re: Adding an external link to catagories menu

Correct
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #7  
Old 03-12-2009, 05:44 PM
  sjb1218's Avatar 
sjb1218 sjb1218 is offline
 

Newbie
  
Join Date: May 2008
Posts: 7
 

Default Re: Adding an external link to catagories menu

It worked...sort of...the link shows up between the 2 menus...here's the link: http://www.fcgbsupplies.com/ I want it in the category menu...can it be moved?
__________________
Sharon
X-cart 4.1.9
Reply With Quote
  #8  
Old 03-13-2009, 02:23 AM
 
balinor balinor is offline
 

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

Default Re: Adding an external link to catagories menu

You need to move it IN the includes of the category template - meaning before this line of code:

{/capture}
{ include file="menu.tpl" dingbats="dingbats_categorie.gif" menu_title=$lng.lbl_categories menu_content=$smarty.capture.menu cellpadding=$fc_cellpadding}
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote

The following user thanks balinor for this useful post:
sjb1218 (03-16-2009)
  #9  
Old 03-14-2009, 11:07 AM
 
marketing@kifaru.net marketing@kifaru.net is offline
 

Member
  
Join Date: May 2006
Location: Golden, Colorado USA
Posts: 10
 

Default Re: Adding an external link to catagories menu

I need to do the same thing (create external links from categories), but keep getting a failure.

mine looks like this though:
{*
$Id: categories.tpl,v 1.33 2008/11/06 16:53:53 max Exp $
vim: set ts=2 sw=2 sts=2 et:
*}
{capture name=menu}
{if $active_modules.Fancy_Categories}
{include file="modules/Fancy_Categories/categories.tpl"}
{assign var="additional_class" value="menu-fancy-categories-list"}
{else}
<ul>
{foreach from=$categories_menu_list item=c}
<li><a href="home.php?cat={$c.categoryid}" title="{$c.category|escape}">{$c.category}</a></li>
{/foreach}
</ul>
{assign var="additional_class" value="menu-categories-list"}
{/if}
{/capture}
{include file="customer/menu_dialog.tpl" title=$lng.lbl_categories content=$smarty.capture.menu}

where do I insert the above mentioned line? Thanks for any help - I'm pulling my hair out over this! Margaret
__________________
Confused in colorado
xcart gold 4.2 (linux)
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 03:54 PM.

   

 
X-Cart forums © 2001-2020