As we learned earlier, roles can be scoped by the portal, by a community, or by an organization. This means that the role only takes effect for the scope in which it resides. For example, a Message Boards Administrator role with complete access to the Message Boards portlet would have different permissions based on the role's scope. If it's a portal role, members have permission to administer message boards across the portal. If it's a community role, members have permission to administer message boards only within the community in which they are members of the role. If it's an organization role, members have permission to administer message boards only within the organization in which they are members of the role.
We also use the word scope to refer to the data set of a portlet. When a portlet is added to a page in a community or organization, it is scoped for that community or organization. This means that its data belongs to that community or organization. If the portlet is added to a page in a different community or organization, it will have a completely different data set. This is how the Message Boards portlet can be placed in one community and have one set of categories and threads, and then be placed in a different community and contain a completely different set of categories and threads.
One limitation of this is that by default, you can have only one Message Boards portlet per community or organization. If you have one Message Boards portlet on one page in a community and you add the portlet to another page in the same community, the second Message Boards portlet will contain exactly the same data as the first, and this is because of its scope. It is scoped for that community. Many of Liferay's portlets work this way.
To get around this, some Liferay portlets can have scopes that go beyond just the specific community or organization upon which the portlet has been placed. You can now scope them by page. If you set the scope of a portlet to be the page instead of the whole community or organization, you can add any number of these portlets to different pages, and they will have different sets of data. This allows you to have more than one message board per community or organization if you wish. All portlets, however, default to the "native" configuration, and have their scopes set to the community or organization where they are placed.
Unless otherwise noted, all of the portlets in this chapter support scoping by either the page or the community / organization to which they belong. This gives you much more flexibility in how you want to set up your portal. By default, however, the scope remains the same as it always has, and is set to be by the community or organization. If you want to change the scope, it only takes a few simple steps.
Illustration 71: Changing the scope for a portlet
That's all it takes to change the scope for a particular portlet instance. By setting the scope to page, you can add as many of these portlets to a particular community or organization as you want, provided they all are added to different pages.