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)
-   -   Remove Location Breadcrumbs from Home (https://forum.x-cart.com/showthread.php?t=14223)

Kshock 05-27-2005 12:02 AM

Remove Location Breadcrumbs from Home
 
Is there any way that I can prevent displaying the breadcrumb navigation links that appear at the top of each store page just on the store Home page? That's the only page I don't want them to appear.

I presume there's some conditional I might add to the /customer/home.tpl template where this line appears:

Code:

{include file="location.tpl"}

But I don't know if there's a global var I can check in Smarty that tells me whether or not I'm currently viewing the store home page??

Thanks.

shan 05-27-2005 03:37 AM

look in home_main.tpl see the elseif statements. look for the one that includes welcome.tpl

Kshock 05-27-2005 11:02 AM

Thanks for the tip, Shan.

For anyone interested, this is how I turned off the breadcrumbs on the store homepage only: In the /customer/home.tpl file, replace this line...

Code:

{include file="location.tpl"}

...with these lines...

Code:

{if $main ne "catalog" or $current_category.category ne ""}
{include file="location.tpl"}
{/if}


Now the breadcrumb navigation links appear on all pages except for the Store homepage.

puzzles 12-11-2005 10:18 AM

A follow up on this - how do we have the breadcrumbs appear *only* on the product pages?

So they don't show up:
- on the home page (got that one covered!)
- on the category pages
- on the non shopping pages we create (like customer service policies and contact us)
- on the search page

puzzles 12-11-2005 10:22 AM

Aha! Figured it out!

{if $product.productid ne ""}
{include file="location.tpl"}
{/if}

divinechic 01-25-2008 09:34 PM

Re: Remove Location Breadcrumbs from Home
 
Works great for Gold Version 4.1.9. Thanks

swifty 02-07-2008 02:59 PM

Re: Remove Location Breadcrumbs from Home
 
thanks, i've been looking for this.

Jon 02-07-2008 03:45 PM

Re: Remove Location Breadcrumbs from Home
 
Note for products, there may be instances where $products.productid is defined and the user is not on the product page, so it is better to use this for product pages only:

{if $main eq "product"}
{include file="location.tpl"}
{/if}

ARW VISIONS 02-07-2008 06:26 PM

Re: Remove Location Breadcrumbs from Home
 
{if $main ne "catalog" or $current_category.category ne ""}
What does the 'ne' ? mean

Shopkeeper09 02-13-2008 07:12 AM

Re: Remove Location Breadcrumbs from Home
 
How do you highlight the current page in the breadcrumb trail?

ETA: Found my answer - go to the css and find the .NavigationPath class and change the font color, decoration, etcetera...
Any hard coding changes you would like to make would be in the location.tpl file under skin1.

ecommerce 05-26-2008 11:27 AM

Re: Remove Location Breadcrumbs from Home
 
Quote:

Originally Posted by Jon
Note for products, there may be instances where $products.productid is defined and the user is not on the product page, so it is better to use this for product pages only:

{if $main eq "product"}
{include file="location.tpl"}
{/if}


Guys,
I want the breadcrumb to appear ONLY in the catergories pages
and in the products pages.

What would be the code?

Thanks

Jon 05-26-2008 11:30 AM

Re: Remove Location Breadcrumbs from Home
 
{if $main eq "product" OR ($main eq "catalog" AND $current_category.categoryid gt 0)}
{include file="location.tpl"}
{/if}

merbay 05-26-2008 05:19 PM

Re: Remove Location Breadcrumbs from Home
 
Thanks to Kshock for such easy to follow directions for a newbie!

ecommerce 05-26-2008 08:36 PM

Re: Remove Location Breadcrumbs from Home
 
Thanks JON!

bpearch 10-08-2008 12:26 AM

Re: Remove Location Breadcrumbs from Home
 
Thanks for the Mod, should be standard on x-cart gives the first page a really good look
Thanks again Colin
www.jollybranding.co.uk
www.coolblades.co.uk

JWait 10-08-2008 06:11 AM

Re: Remove Location Breadcrumbs from Home
 
There are things that should be standard, and things that shouldn't. This is one of the latter. It is easy enough to modify the way it is if you want, and would be difficult to figure out where to add it if you don't think it gives the first page "a really good look".

And to Ashley... ne is "not equal".

royng 10-10-2008 08:51 AM

Re: Remove Location Breadcrumbs from Home
 
Thanks! Kshock http://forum.x-cart.com/images/statusicon/user_offline.gif vbmenu_register("postmenu_83256", true);

U are better than the support desk!

ARW VISIONS 10-10-2008 10:07 AM

Re: Remove Location Breadcrumbs from Home
 
Quote:

Originally Posted by JWait
There are things that should be standard, and things that shouldn't. This is one of the latter. It is easy enough to modify the way it is if you want, and would be difficult to figure out where to add it if you don't think it gives the first page "a really good look".

And to Ashley... ne is "not equal".


Ummm... I made that post in February. I figured it out since then. but thanks anyways.

8)8)8)

DOD467 04-07-2009 10:53 AM

Re: Remove Location Breadcrumbs from Home
 
what if you wanted to replace the breadcrumbs with the word "Welcome!" on the home page?

{if $main ne "catalog" or $current_category.category ne ""}
{include file="location.tpl"}
{/if}

balinor 04-07-2009 11:33 AM

Re: Remove Location Breadcrumbs from Home
 
{if $main eq "catalog" and $current_category.category eq ""}
Welcome!
{/if}

DOD467 04-07-2009 11:50 AM

Re: Remove Location Breadcrumbs from Home
 
Thanks Balinor, once again...

I am having a problem when I have the following:

{if $main ne "catalog" or $current_category.category ne ""}
{include file="shared/navigation/breadcrumbs.tpl"}{/if}
{if $main ne "catalog" or $current_category.category ne ""}
Welcome! {/if}

"Welcome" does not show, any ideas?

balinor 04-07-2009 12:24 PM

Re: Remove Location Breadcrumbs from Home
 
Please look at my code again, you didn't copy it exactly.

DOD467 04-07-2009 12:26 PM

Re: Remove Location Breadcrumbs from Home
 
Yes I did, but then the breadcrumbs do not show up on the other pages. This is why I need it changed.

THnaks

balinor 04-07-2009 12:28 PM

Re: Remove Location Breadcrumbs from Home
 
What do you want to do? Show welcome on the home page and location breadcrumbs on the other pages? If so, use this:

{if $main eq "catalog" and $current_category.category eq ""}
Welcome!{else}{include file="shared/navigation/breadcrumbs.tpl"}{/if}

Meredith Martin Davis 07-01-2009 09:49 AM

Re: Remove Location Breadcrumbs from Home
 
To add on to all of this, how can I get breadcrumbs to show up only on product pages and sub-category pages?

At the moment, for products only, I have:

{if $main eq "product"}
{include file="location.tpl"}
{/if}

Thanks!

lash 11-04-2009 07:01 AM

Re: Remove Location Breadcrumbs from Home
 
Quote:

Originally Posted by Jon
{if $main eq "product" OR ($main eq "catalog" AND $current_category.categoryid gt 0)}
{include file="location.tpl"}
{/if}


Where do I add this code?

ARW VISIONS 11-04-2009 07:05 AM

Re: Remove Location Breadcrumbs from Home
 
you replace this
{include file="location.tpl"}

with this

{if $main eq "product" OR ($main eq "catalog" AND $current_category.categoryid gt 0)}
{include file="location.tpl"}
{/if}

location.tpl is probably in home.tpl

lash 11-04-2009 07:15 AM

Re: Remove Location Breadcrumbs from Home
 
Quote:

Originally Posted by Ashley
you replace this
{include file="location.tpl"}

with this

{if $main eq "product" OR ($main eq "catalog" AND $current_category.categoryid gt 0)}
{include file="location.tpl"}
{/if}

location.tpl is probably in home.tpl


Thanks I will try that. I guess it is the same place where you remove the breadcrumb for home, which I already did and it looks so much better..

lash 11-04-2009 07:41 PM

Re: Remove Location Breadcrumbs from Home
 
Thanks for all contributions in this thread. Works like a charm and no way I would have been able to figure that out myself.


All times are GMT -8. The time now is 04:59 AM.

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