Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the difference between IPloneSiteRoot and ISiteRoot in Plone?

Tags:

plone

zope3

I'm Working in Plone 4.1 and I'm just curious to know the difference between Products.CMFPlone.interfaces.IPloneSiteRoot and Products.CMFCore.interfaces.ISiteRoot. If I want to register a zope-3 style view, to which one should I register it?

like image 854
Noe Nieto Avatar asked Dec 10 '22 08:12

Noe Nieto


1 Answers

Whenever I want to use a site root, I usually end up using the INavigationRoot from plone.app.layout.navigation.interfaces.INavigationRoot instead.

The INavigationRoot is provided by the Plone site object, but it will also be provided by the navigation root of any subsite or the top level folders in a multi-lingual site. Especially in multi lingual sites, users will never navigate or see the actual site root itself, so any functionality attached to it won't be available to them.

The ISiteRoot only makes sense for things like export import handlers or other internal logic, but not for any enduser visible functionality.

like image 120
Hanno Schlichting Avatar answered Jun 14 '23 01:06

Hanno Schlichting