Foros de discusión

[RESOLVED] virtual hosting for user pages

thumbnail
Assaf Yakir, modificado hace 14 años.

[RESOLVED] virtual hosting for user pages

New Member Mensajes: 17 Fecha de incorporación: 30/01/09 Mensajes recientes
Hi everyone,

I've been searching the forums for the last couple of days for a way to implement virtual hosting for user page. I found only this one
post asking the same question, but the guy was told there that it's not possible in LP5+ and that the feature existed prior to that but was deprecated or removed. Overall, the issue was left unclear.

I'm using 5.2.3 with tomcat 6.
Does anybody know if it's possible to set virtual hosting for user public and private layouts? Why was this feature removed?

I wanted my users to have their own subdomain names for public and private pages for easy access via URL. Any thoughts would be very much appreciated.

Thanks,

Assaf
thumbnail
Josh Asbury, modificado hace 14 años.

RE: virtual hosting for user pages

Expert Mensajes: 498 Fecha de incorporación: 8/09/06 Mensajes recientes
I read somewhere on the forums that it is currently not possible -- and I can't remember this even being possible in the 4.x days. Regardless, the best way to handle it for now is probably at the web server level by redirecting to the full URL.

Here's an example from my httpd-vhosts.conf file:
<virtualhost *:80>
    ServerName user.domain.net
    RewriteEngine On
    RewriteRule ^ http://www.domain.net/web/user/home
</virtualhost>
thumbnail
Assaf Yakir, modificado hace 14 años.

RE: virtual hosting for user pages

New Member Mensajes: 17 Fecha de incorporación: 30/01/09 Mensajes recientes
Hi Josh,

Sorry it took me a while to reply, I got distracted with another project.

First of all, thanks for your suggestion, that's pretty much what I would have done, but I don't know, it feels kind of "patchy". I was hoping for a more programmatic solution from within Liferay's core. Maybe it should be proposed as a feature for future development.

Still, I wouldn't mark this issue as RESOLVED since I hope maybe someone can come up with another solution.

Thanks again,

Assaf
Nidecker Nidecker, modificado hace 14 años.

RE: virtual hosting for user pages

New Member Mensajes: 9 Fecha de incorporación: 7/03/06 Mensajes recientes
I got it working on 5.2.3 by directly setting the virtualHost value in the layoutset table.
thumbnail
Assaf Yakir, modificado hace 14 años.

RE: virtual hosting for user pages

New Member Mensajes: 17 Fecha de incorporación: 30/01/09 Mensajes recientes
Nidecker, you're my savior!

That's exactly what I was hoping for. I've just tried it and it works like a charm.

I should have checked the tables myself before posting. I would hate to have to start rewriting my urls through the server. And it would have been especially tricky since my Apache is in the back, behind the Tomcat, just serving 3rd party apps into liferay. Your solution is great, since it's just using Liferay's own capabilities, as it should be.

But the question remains: If user pages are rendered exactly like organizations and communities, and if all of the infrastructure is the same and is there, waiting to be utilized, why is this ability disabled? But I guess this solution should work for others, until it will be featured in future releases.

Thanks again guys.

Hope nothing else breaks.