Login

Username

Password





Register   Reset password

This is a read-only archive of the forum.

# baldec 10/23/2008 10:33 AM
How tightly integrated is the sitemap module to the Cuyahoga core code? I was hoping that it was a standalone module that one could modify to not do silly things(explanation follows) though I can't find it as a stand along project in the source.

The reason that I am saying it does silly things is that it shows pages that aren't supposed to be shown in navigation, with no possibility to remove those pages either.

And the idea I have is to add the config option to "Do not show hidden pages" Or something along that road. Can ofc, create this module from scratcht but if time can be put to other use... :)

Dunno if I make sense atm due to general tired mode turned on but perhaps someone have some bright comment that might help :)
# ernesto 10/23/2008 10:48 AM
Check the menu module (cuyahogaContrib), it has an option to render the nodes in siteMap mode. It consider the "show in navigation" option. Example: http://www.intervida.org/mapa-web.aspx
# baldec 10/23/2008 11:50 AM
Thank you ernesto, hadn't thought of using that module to sort the sitemap function.

I did find the code for the sitemap module that comes with Cuyahoga though and did a quick fix in that instead.

I just added
&& (node.ShowInNavigation == true)

to the lines in GenerateSitemap() and BuildListItemFromNode() where the checks for user priviliges was made. And also wrapped the root node in the following test.
if (base.PageEngine.RootNode.ShowInNavigation == true)
            {
                ------>>>mainList.Controls.Add(BuildListItemFromNode(base.PageEngine.RootNode));
            }

The arrow points to the original line and the other is the wrap around.

So it was a quite easy fix to make it work as I wanted it, though to do it properly one should break it out to a standalone module for upgrade purposes.
# YKS 10/24/2008 9:40 AM
We dont modify Cuyahoga.Core for maintence compatibility with next versions.
# baldec 10/27/2008 10:37 AM
YKSWe dont modify Cuyahoga.Core for maintence compatibility with next versions.

Thus me saying I should break it out to a standalone module for the future upgrades .) Though for now it is solved and I have the breakout on the todo-list for the coming 2 weeks.

First meet the deadline, then make it the correct way.