構造的に表示 平面上に表示 ツリー上に表示
スレッド [ 前へ | 次へ ]
toggle
Thomas Berg
[RESOLVED] Removing /web/guest in Liferay 6.1
2012/08/01 3:17
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

We are moving from Liferay 6.0.5 and have been able to access pages in the guest community without writing /web/guest and without using .htaccess

Let's say we have a page in the guest community name example-page. Instead of writing http://www.example.com/web/guest/example-page I want the page to be accessible with http://www.example.com/example-page

With Liferay 6.1 (upgraded from 6.0.5), I have not been able to get this to work. I've looked at different posts but nothing seems to work. If possible, I do not want to resort to using .htaccess. Can anyone give me detailed, step-by-step information about how to acheive this?

/ Thomas

EDIT :
Well, this is embarrassing emoticon

Turns out that I had been overzealous in disabling filters in portal-ext.properties...
I had somehow managed to disable the VirtualHostFilter! No wonder my setup broke ... Your solutions works of course!

I apologize for this stupid mistake, thanks for all the help guys emoticon

Regards
/ Thomas
Hitoshi Ozawa
RE: Removing /web/guest in Liferay 6.1
2012/07/24 4:23
答え

Hitoshi Ozawa

ランク: Liferay Legend

投稿: 7949

参加年月日: 2010/03/23

最近の投稿

Have you looked at the following thread?

http://www.liferay.com/community/forums/-/message_boards/message/13165118
Thomas Berg
RE: Removing /web/guest in Liferay 6.1
2012/07/24 6:04
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

Thanks for your reply Hitoshi!

Yes, I've looked at that thread but unfortunately, I cannot start over with a fresh install since we're upgrading.

The virtual host for our (only) portal instance is set to example.com. I cannot change this to a blank value. When trying to use the same for the guest community, an error message stating "Please specify a unique virtual host" is shown.
elias saliba
RE: Removing /web/guest in Liferay 6.1
2012/07/24 7:00
答え

elias saliba

ランク: New Member

投稿: 24

参加年月日: 2012/07/16

最近の投稿

hi thomas,

1- Login in as portal administrator.
2- Go to Control Panel > Site Setting. (left menu)
3- Click on “Site URL“.(right menu)
4- Key in your desired domain in the “Public Pages” field (you can leave the Private Pages blank).
5- Save your changes.
6- You should be able to access the portal via your new domain (thomas.com:8080) and “/web/guest” has been remove from the URL.


hope this will help you.
keep us updated.
Hitoshi Ozawa
RE: Removing /web/guest in Liferay 6.1
2012/07/24 14:26
答え

Hitoshi Ozawa

ランク: Liferay Legend

投稿: 7949

参加年月日: 2010/03/23

最近の投稿

Your steps seems to the same as those given by Mike in the thread I've mentioned (the last post). Thomas probably got the notion that it has to be a fresh install from the first statement.

This works with a fresh install of LR 6.1. Here's the steps :

Create an entry in your hosts file, for example "127.0.0.1 mysite.com"
In Control Panel -> Sites -> Edit Site Settings
Site URL : Just enter "mysite.com" in the field "Public Pages". Don't change anything else.


BTW, if links in web content portlet contains web/guest/, they have to be fixed.
Thomas Berg
RE: Removing /web/guest in Liferay 6.1
2012/07/25 0:47
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

Hi Elias and Hitoshi
Thanks for trying to help!

I was able to change the virtual host from mydomain.com to localhost for my portal instance by setting

1 company.default.web.id=mydomain.com

(was not a valid domain before)

Before I changed the company.default.web.id I was not able to set localhost as the value of Virtual Host for the portal instance. The error message "Please enter a valid Virtual Host" was shown.

So now I can set mydomain.com as the value of Public Pages for the guest community (named mydomain.com).
But even though the address of example-page is now set as http://mydomain.com/example-page, I get the following error in the log when trying to get to it:

109:18:35,289 WARN  [404_jsp:109] /example-page


Entering http://mydomain.com/web/guest/example-page gives the error net::ERR_TOO_MANY_REDIRECTS in Chrome.

So, we're (possibly) making progress but not quite there yet :-)
Oliver Bayer
RE: Removing /web/guest in Liferay 6.1
2012/07/25 1:15
答え

Oliver Bayer

ランク: Liferay Master

投稿: 889

参加年月日: 2009/02/18

最近の投稿

Hi Thomas,

I've faced the error ERR_TOO_MANY_REDIRECTS a while ago. Deleting the cookies and the browser cache solves the issue (at least it did it in my case emoticon).

HTH Oli
Thomas Berg
RE: Removing /web/guest in Liferay 6.1
2012/07/25 2:54
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

Thanks Oli, good tip!

I discovered that I had set
1virtual.hosts.default.site.name=
2instead of
3virtual.hosts.default.site.name=Guest

Changing this back fixed "ERR_TOO_MANY_REDIRECTS".

But it does not solve my problem i'm afraid emoticon

The address mydomain.com/home stil gives me WARN [404_jsp:109] /home instead of serving the page even though the url of the page looks like this:
画像の固定

添付ファイル: page-url.png (8.5k)
Thomas Berg
RE: Removing /web/guest in Liferay 6.1
2012/07/30 16:56
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

So now I've lost /web/guest and get directed to http://mydomain.com/home when entering http://mydomain.com but the page is not served.
Instead I get WARN [404_jsp:109] /home... All pages in the Guest site are accessible by entering http://mydomain.com/web/guest/<page-name> which is fine, I just need them to also be available when entering http://mydomain.com/<page-name> (without /web/guest being added to the url).

All Wiki's and Forum posts seem simple enough but I just cannot get it to work!

I've successfully set the virtual host for the only portal instance to localhost and set the virtual host for the Guest-site to mydomain.com

My /etc/hosts looks like this:

1127.0.0.1 localhost
2a.b.c.d mydomain.com


Which settings in portal-ext.properties are involved in this and what values are you guys using for them?

1company.default.web.id=mydomain.com
2company.default.home.url=/web/guest
3virtual.hosts.default.site.name=Guest


Please, does anyone have an idea about which settings i've missed or set wrong? emoticon
Arno Broekhof
RE: Removing /web/guest in Liferay 6.1
2012/07/31 3:08
答え

Arno Broekhof

ランク: Junior Member

投稿: 42

参加年月日: 2011/10/18

最近の投稿

The settings:
1
2company.default.web.id=mydomain.com
3company.default.home.url=/web/guest


are not necessary.

why would you alter the hosts file? are you running apache or some other server as reverse proxy? if you give me more details on you're configuration i can help you.
Arvind Gupta
RE: Removing /web/guest in Liferay 6.1
2013/05/16 2:09
答え

Arvind Gupta

ランク: Junior Member

投稿: 29

参加年月日: 2012/12/17

最近の投稿

Hi did you find the solution i am also facing the same issue it is keep on going the below error:

13:11:00,479 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,489 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,509 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,519 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,539 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,549 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,565 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,586 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
13:11:00,596 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus
06:11:49,755 WARN [ajp-bio-8009-exec-1][404_jsp:109] /aboutus

I am using using apache2.2 in front of liferay .
Thomas Berg
RE: Removing /web/guest in Liferay 6.1
2013/05/16 3:51
答え

Thomas Berg

ランク: Regular Member

投稿: 134

参加年月日: 2009/09/07

最近の投稿

Hello Arvind,
Please see my Edit (the first post).

I had made a mistake while removing unneeded filters and also removed the VirtualHostFilter emoticon
The solutions provided by the other guys in this thread does work!

Hope you'll get it working too!

Regards
Thomas
Arvind Gupta
RE: Removing /web/guest in Liferay 6.1
2013/05/24 0:01
答え

Arvind Gupta

ランク: Junior Member

投稿: 29

参加年月日: 2012/12/17

最近の投稿

Thanks Thomas I missed that point.
Ed Quigley
RE: [RESOLVED] Removing /web/guest in Liferay 6.1
2013/08/16 7:28
答え

Ed Quigley

ランク: New Member

投稿: 1

参加年月日: 2013/03/11

最近の投稿

So. I just want to confirm that for Liferay 6.1 this solution works. There is no /web/guest in the urls presented to visitors and links do not require /web/guest and references to Liferay assets such as images do not require /web/guest. I just want to be sure of the path, before I follow it.