Jump to content

[SOLVED]Confusion: Categories page & Home page?


Recommended Posts

In Home page when I click on Categories tab I am directed to a page with iPods, Accessories and Laptop images. Logically I am supposed to be directed to the Categories page BUT in the top of the page it says:
Home >
HOME There are no products.
Subcategories

So what this page is? Home page or Categories page?
Basically the Home page (index) is the first page when the store is open in the Browser.
I am confused. Either I misunderstood the logic of navigation in the Prestashop or there should be another reason that I ignore.
I'd appreciate any explanation or clarification. (please see the screen shot)
Bruce

36018_thtXif5n5az7uuL7l1h8_t

36019_HIDF4aPA0QLDLfLdnQ7G_t

Link to comment
Share on other sites

Rocky,
First, Happy New Year.

It’s the “Home” category, not the homepage, so I suppose the breadcrumb should read Home > Home,

How can I modify the breadcrumb to read Home >Categories instead of Home > Home?

, unless you edited your database and changed the name of category 1 from “Home” to something else.

Sorry I didn't understand your point. I don't have the words "category1" and "Home" in my database.
Can you elaborate more please?
Thanks.
Link to comment
Share on other sites

It worked. Thanks.
Now I have another question.
In Front Office:
it displays "Categories: There are no products." even though there are 3 categories iPods, Accessories and Laptops.
In Back Office:
It displays: "4 products" in category "Categories".
Which information is correct, in Back Office or in Front Office? Can we consider that there products in Category?
Actually I am confused with this file management or utilization of these vocabulary Category, Subcategory and Home.
I hope that make sense.
(please see screen shots)
Thanks.

36111_t4MMNvhIa0rqJAysawcb_t

36112_rpW4rSDjq9w2BGORpBSm_t

Link to comment
Share on other sites

I don't think the PrestaShop team ever really intended the "Home" category to be displayed, which is why it doesn't display like other categories. I suggest that you change lines 5-15 of category.tpl in your theme's directory from:

{strip}
   {$category->name|escape:'htmlall':'UTF-8'}

       {if $nb_products == 0}{l s='There are no products.'}
       {else}
           {if $nb_products == 1}{l s='There is'}{else}{l s='There are'}{/if} 
           {$nb_products} 
           {if $nb_products == 1}{l s='product.'}{else}{l s='products.'}{/if}
       {/if}
{/strip}



to:

{strip}
   {$category->name|escape:'htmlall':'UTF-8'}
   {if $smarty.get.id_category > 1}
       {if $nb_products == 0}{l s='There are no products.'}
       {else}
           {if $nb_products == 1}{l s='There is'}{else}{l s='There are'}{/if} 
           {$nb_products} 
           {if $nb_products == 1}{l s='product.'}{else}{l s='products.'}{/if}
       {/if}
{/if}{/strip}



This should hide the "There are no products" text on the home category.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...