svanschu / SchuWeb-Sitemap

SchuWeb Sitemap is a sitemap generator for Joomla CMS
GNU General Public License v3.0
13 stars 9 forks source link

Remove duplicate: removed too much links/menu items #118

Closed peterhulst closed 9 months ago

peterhulst commented 9 months ago

Steps to reproduce With Remove duplicate: YES and Remove duplicate menu: YES

Expected behavior With Remove duplicate: YES and Remove duplicate menu: YES, all five menu items should be visible in the side map, but with duplicated links/articles removed.

Actual result With Remove duplicate: YES and Remove duplicate men: two of five menu items are visible in the side map and thus too less links/articles are visible

System information Joomla version: 4.4.2 SchuWeb-Sitemap version: 5.0.0 PHP version: 8.1.26 Database version: 10.5.22-MariaDB-cll-lve

svanschu commented 9 months ago

Hi @peterhulst

to reproduce your issue i need more information.

Which menu types are within that menu, so I can see where the logic hits. Which URLs are within that menu.

Thank you

peterhulst commented 9 months ago

Hello,

See: https://joomla4.loopgroepbedum.nl/sitemap-loopgroep-bedum?view=sitemap&id=1

Remove Duplicate: YES

Menu:

  1. https://joomla4.loopgroepbedum.nl/
  2. Information: IN SITEMAP
  3. Recent: NOT IN SITEMAP
  4. Archive: NOT IN SITEMAP
  5. Contact: IN SITEMAP
  6. Login: IN SITEMAP
svanschu commented 9 months ago

Ah ok I see I see, because Information Recent and Archive are "empty" menu items for structuring. So technically they are the same, but logically they are not.

Information, Recent and Archive are of type "System Links" " Menu heading" ?

peterhulst commented 9 months ago

These menu items are: Menu Item Type: Separator (via System Link, Separator). But you can also use: Menu Heading.

Regards.

svanschu commented 9 months ago

Can you test if this fixes your issue?

pkg_schuweb_sitemap_5.0.1-b1_20240116.zip

peterhulst commented 9 months ago

Hello, Your fix works perfect: the duplicates are removed! Thanks!

For the menu item: Archief under joomla4.loopgroepbedum.nl only the first level is shown. A special component (SectionEx, which I have converted to Joomla 4) is used. I will update a plugin (SchuWeb Sitemap - SectionEx Plugin) which is already available for Joomla 3. See https://www.loopgroepbedum.nl/sitemap-loopgroep-bedum for this plugin in action. (the plugin for J3 can be downloaded: https://www.loopgroepbedum.nl/archief/downloads/Joomla-3-Extensions/ )

svanschu commented 9 months ago

Nice, then you will be first entry of a third party list :)