Support Forum

rokSprocket and breadcrumb issue

vincent
vincent
Offline
This was originally posted on RT forum, but their support doesn't make much sense as always. And I know this doesn't have much to do with IT's products, I am merely seeking some suggestions; moreover, since many of IT's particles also functions similar to rokSprocket(listing contents), I think this is somewhat relevant.
*************************************************************************************************************
rokSprocket is a great extension, I prefer using it to construct my article list page. But I am always troubled by a problem, described as follow.

I believe what I want is quite simple and common to many users:

On article list page, Mosaic displays a list of articles which users can click to enter the article page;
On article pages, the Mosaic module doesn't display, and Breadcrumb shows something like "Home>category>article";
When users click "category" in the breadcrumb, they will be back to the aforementioned article list page.


To my surprise, this is actually quite hard to achieve without hard coding. I will try to explain my approaches:
Firstly, on the article list page, since there is already the Mosaic module listing the articles, I don't want the "page content" to display, to do this, I can either use Gantry5's custom page as menu item type, or create and use an outline(tempalte) without the "page content" position, then select "category blog" as menu item type.
If I use custom page, since there is no menu item associated with the articles or their category, the article pages will inherit homepage's itemid, hence displaying modules that are only supposed to be shown on homepage, moreover the breadcrumb won't be showing because we ususally don't show breadcrumb on homepage. Some might suggest create a hidden Category Blog page, but this way the breadcrumb on article page won't be right: although it shows "home>category>article", the "category" would only link to the hidden page, which will lead to the following issue -
If I use the Category Blog menu item, then besides Mosaic module, the article list page will display another list of articles(coming from com_content). To hide the additional article list, like what was mentioned above I can create a outline without "page-content". But now the article page will be blank too because it is also using the no-page-content outline.

Now maybe the simplest way to overcome this is using CSS to block the "page-content" on "Category Blog" page only. But I really don't like this workaround because it means redundant loading of the page. I've also tried Module anywhere, but it seems it can't deal with this issue either.

So with current Gantry5 framework and Joomla 3.8.2, is there a way to overcome this problem without writing PHP/CSS/JAVASCRIPT? Is it possible to assign different outlines to the article list page and article page? Not that I can't do coding but if there is a possible solution that requires no coding, I always prefer using it.
Responses (3)
  • Accepted Answer

    Friday, November 10 2017, 02:49 PM - #Permalink
    Hi Shengke,

    Yes, as you've mentioned, this has nothing to do with our products and it has nothing to do with RokSprocket and Rockettheme either.
    This is just how Joomla works.
    Therefore it is out of the scope of support that we provide and I believe it is out of the scope of support that Rockettheme provide.

    The place where you should ask this question is the official Joomla support forum.

    Anyway, Joomla is a menu-centric CMS so the most important thing in any Joomla website is the Menu. It defines the site structure, it defines the URLs, it defines the breadcrumbs, you assign modules to menu items, etc.
    What I would do is the "Hidden Menu" workaround. This is the best and most proper solution in my opinion.

    Actually, we use the "Hidden Menu" workaround on our website (InspireTheme.com). We have another Menu (Documentation) which is not part of the Main Menu.
    Notice that in our Main Menu we have the "Documentation" menu item as a submenu of the "Support" menu item.
    But when you go to the Documentation page, the Breadcrumbs (as you said in your comment) show different thing:

    Home -> Documenation instead of Home -> Support -> Documentation

    Well, this is a design decision that you need to make while building/configuring your website.

    Alright, here's another tip for you - there is an option in the Gantry 5 Menu Editor that allows you to disable the Dropdown menus (see the attached screenshot).
    We use this solution on our website as well. Have a look at the "Templates" menu item - it does not have a submenu because we are hiding it via the Gantry 5 Menu Editor. But in reality, the pages of all our templates are submenu items of the "Templates" menu item (see the second screenshot).
    So I think that this is what you are looking for - imagine that on the Templates page there is the RokSproket module. When you are on the "Templates" page the breadcrumbs show Home -> Templates.
    Then click on the Delight template so you can go to its page and notice that the breadcrumbs show Home -> Templates -> Delight.
    As far as I understand this is exactly what you want to achieve.

    Anyway, I hope that the above information is helpful for you, but as I said this is really a design/configuration decision that you need to take and make on your own.
    The reply is currently minimized Show
  • Accepted Answer

    vincent
    vincent
    Offline
    Friday, November 10 2017, 11:09 PM - #Permalink
    Thank you for your tips. They are all valid and inspiring. For the 2nd one, it is similar to creating hidden menu item for each article, but the breadcrumb can be shown correctly. However, if I have hundreds of templates , then I will have to create hundreds of hidden menu items....

    I think another quite simple way is to create a hidden catogry blog menu item, then on article page, use javascript to change the breadcrumb's link
    The reply is currently minimized Show
  • Accepted Answer

    Saturday, November 11 2017, 02:05 PM - #Permalink
    No problem mate.

    Yep, the Javascript solution sounds good as well.
    Just find the one that works best for you.
    The reply is currently minimized Show
Your Reply

Become an insider | Subscribe to our Newsletter
Subscribe to our mailing list and stay up-to-date with all our awesome releases, latest updates and amazing discount offers!