WebSphere Portal Server - Allowing an anonymous user to choose portal theme

This is Interesting: Free IT Magazines  
Home > Archive > WebSphere Portal Server > June 2007 > Allowing an anonymous user to choose portal theme





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Allowing an anonymous user to choose portal theme

2007-06-15, 7:30 am

Hi,

How can I allow an anonymous user to select the portal theme that will be applied during his navigation? I want the theme to be applied only to the anonymous user who selected it.
Oliver Then

2007-06-15, 7:30 am

Portal does not support "per user theme". You can assign themes to
pages, but you cannot specify different themes for different users.

Oliver

2007-06-15, 7:30 am

Ok, thank you for your answer.
Michael Harris

2007-06-15, 7:30 pm

While Portal does not support different themes per user, it is possible
to write a single theme that changes its behavior based upon the user or
perhaps cookies in the user's browser.

The simplest thing you could do is provide different CSS stylesheets and
instead of the user selecting a different theme, what they actually
select is a different CSS stylesheet.

You could also alter the markup based upon user or cookies, although
that can get complicated depending upon what your requirements are.

2007-06-18, 7:25 am

Cookies may be an option for what I want to do.

Would it be possible to a portlet to read cookies set by the portal theme?

I would need to read cookies from a JSP Component in WCM Content Viewer portlet.
Michael Harris

2007-06-19, 1:19 am

jleno@mail.sogeti-transiciel.com wrote:
> Cookies may be an option for what I want to do.
>
> Would it be possible to a portlet to read cookies set by the portal theme?
>
> I would need to read cookies from a JSP Component in WCM Content Viewer portlet.


I don't know... you'll have to try a test. Many of the Portlet APIs
where you get a value and pass in a key (such as request, session, etc.
attributes) will first check for the namespace encoded version of the
key and if a value isn't found, it will look for the key directly. You
might be able to use this to get a value set in the theme. I know that
it is not possible to go the other way around. i.e. You cannot set a
value in the portlet that is not namespace encoded and therefore would
be accessible by the theme.

Now, if you can use JavaScript in the portlet, you can get and set all
the cookies you want.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com