Fórum

Make Public pages private

thumbnail
Roman Hoyenko, modificado 16 Anos atrás.

Make Public pages private

Liferay Master Postagens: 878 Data de Entrada: 08/10/07 Postagens Recentes
I have a website with a lot of public pages that need to be made private.

What I tried to do is to update tables to change 'PUB.' to 'PRI.' in different tables, but there are some problems.

Here is what I did:

update Resource_ r set r.primKey=(replace(r.primKey, 'PUB.1028', 'PRI.1028'));

update Layout l set l.ownerId = (replace(l.ownerId, 'PUB.1028', 'PRI.1028'));

update LayoutSet set pageCount = 5 where ownerId='PRI.1028';
update LayoutSet set pageCount = 0 where ownerId='PUB.1028';

update JournalContentSearch set ownerId='PRI.1028' where ownerId='PUB.1028';

The problems I have:

The theme changed. Should I update some other table to have the theme changed?

Journal Content articles do not show content. What do I need to do so I can see the content? The portlets are still there, they just don't show the content.
thumbnail
Roman Hoyenko, modificado 16 Anos atrás.

RE: Make Public pages private

Liferay Master Postagens: 878 Data de Entrada: 08/10/07 Postagens Recentes
I got it, I missed this table:

update PortletPreferences set ownerId='PRI.1028' where ownerId='PUB.1028';

worked fine after update.
Vin k k, modificado 16 Anos atrás.

RE: Make Public pages private

Regular Member Postagens: 138 Data de Entrada: 04/12/07 Postagens Recentes
Hi Roman,
I have similar situation, i have one public page under the community i have created, now every one can see the contents(portlet)of the page without login, i want make this page to view only after the successful login. how to do this ??

Thanks
Vin
Vin k k, modificado 16 Anos atrás.

RE: Make Public pages private

Regular Member Postagens: 138 Data de Entrada: 04/12/07 Postagens Recentes
Hi Roman,
I have similar situation, i have one public page under the community i have created, now every one can see the contents(portlet)of the page without login, i want make this page to view only after the successful login. how to do this ??

Thanks
Vin
thumbnail
Ray Auge, modificado 16 Anos atrás.

Re: [Liferay Forums][5. Portal Framework]RE: Make Public pages private

Liferay Legend Postagens: 1197 Data de Entrada: 08/02/05 Postagens Recentes
1) Both users must be part of the community in question.
2) Visit the "Manage Pages (or Page settings)", select the page you want
to protect/share.
3) On the "Page" tab, click the "Permissions" button.
4) Remove all "Guest" permissions, (and depending on your version,
remove all "Community" permissions).
5) Assign VIEW permission to whoever should have access to the page.
thumbnail
Ray Auge, modificado 16 Anos atrás.

Re: [Liferay Forums][5. Portal Framework]RE: Make Public pages private

Liferay Legend Postagens: 1197 Data de Entrada: 08/02/05 Postagens Recentes
You can get around this first requirement if the user is part of a "User
Group" and you give VIEW permission to the "public" page to this User
Group. BUT, they won't have the Community in their "My Places"
submenu...so they'll have to know the URL.

>
> 1) Both users must be part of the community in question.
> 2) Visit the "Manage Pages (or Page settings)", select the page you want
> to protect/share.
> 3) On the "Page" tab, click the "Permissions" button.
> 4) Remove all "Guest" permissions, (and depending on your version,
> remove all "Community" permissions).
> 5) Assign VIEW permission to whoever should have access to the page.
shaun pollock, modificado 16 Anos atrás.

RE: Re: [Liferay Forums][5. Portal Framework]RE: Make Public pages private

New Member Postagens: 5 Data de Entrada: 16/02/08 Postagens Recentes
How do i change the behavior of the Add Page link to add private pages to the user rather than a community wide page , which it does by default ?

Thx
Tommy Tommson, modificado 14 Anos atrás.

RE: Re: [Liferay Forums][5. Portal Framework]RE: Make Public pages private

Junior Member Postagens: 30 Data de Entrada: 25/05/09 Postagens Recentes
Is there a possibility to make public pages really private without only fixing the permissions? So that they appear as private pages when I select them via the control bar > My Places > Community > Private ?
Senthil Chockalingam, modificado 12 Anos atrás.

RE: Make Public pages private

New Member Postagens: 3 Data de Entrada: 30/11/09 Postagens Recentes
Hi Hoyenko,

I am using the Liferay 5.2.3 version with Mysql server in linux environment.

And in my lportal schema, ownerId field is missing in Layout, LayoutSet tables.

Please let me know that, how can run the below queries in my db.

  • update Layout l set l.ownerId = (replace(l.ownerId, 'PUB.1028', 'PRI.1028'));
  • update LayoutSet set pageCount = 5 where ownerId='PRI.1028';
  • update LayoutSet set pageCount = 0 where ownerId='PUB.1028';


And in my Resource_ table, the primKey field contains only 5 digit no like (47655). It is not like this format PRI 47655.

So tell me how to run the below query

  • update Resource_ r set r.primKey=(replace(r.primKey, 'PUB.1028', 'PRI.1028'));


As well as, in JournalContentSearch table, same issue.

The ownerId field is missing.


Please guide me, to move the public community pages to private community pages using DB.

Regards,
Senthil
thumbnail
David H Nebinger, modificado 12 Anos atrás.

RE: Make Public pages private

Liferay Legend Postagens: 14918 Data de Entrada: 02/09/06 Postagens Recentes
Senthil Chockalingam:
Please guide me, to move the public community pages to private community pages using DB.


Not possible. Liferay purposefully obfuscates their DB because the API relies upon it heavily. There's also indexing and other portions of Liferay that can break if you go tinkering w/ the database.

A golden rule of using Liferay is to never modify the database directly.
Senthil Chockalingam, modificado 12 Anos atrás.

RE: Make Public pages private

New Member Postagens: 3 Data de Entrada: 30/11/09 Postagens Recentes
Hi David,

Thanks for the Quick response.

But one of my client is created a community (with 130 public pages). I want to bring that community as private i.e(In any way i have to bring that community under group url).

Is there any possibilities emoticonemoticon
Senthil Chockalingam, modificado 12 Anos atrás.

RE: Make Public pages private

New Member Postagens: 3 Data de Entrada: 30/11/09 Postagens Recentes
Some times the bulk Export/Import is not functioning properly.
thumbnail
Hitoshi Ozawa, modificado 12 Anos atrás.

RE: Make Public pages private

Liferay Legend Postagens: 7942 Data de Entrada: 24/03/10 Postagens Recentes
I think you may need to change permission/role tables too. Pages are very complicated and I've found out it's better not to try to do it directly using sql commands. I've also found that it can be done easily with portlets.