Hello David,
thanks a lot for your help, but unfortunately it dosen't work like that.
The pages with the portlets are not generated from the psml, when I
include this portlet in the portlet registry and refer to it in psml
files. The problem probably is, that you use a hard link to the psml
file of the admin (I tried to include this portlet in the psml of the
admin and not the other users, but it doesn't work either). Is there no
way to register the portlet with an relative path to the psml file,
where the portlet is used? Or maybe a different way to call the action
JLogoutUser?
I don't know what the problem is, but none of the pages, generated from
the psml files, are actually generated. All you can see is an empty page.
Thanks a lot,
Sven.
David Sean Taylor schrieb:
Jacek Wiślicki wrote:
Wiadomosc od Sven Richter z 2005-09-07 00:05 brzmiala:
At the moment I'm using a logout portlet the user can reach by
clicking on a tab, which is then showing a page with the logout
portlet. Now I'm trying to find a way to implement an Action, where
a user can logout by simply clicking on the tab.
Is that even possible?
Normally its done thru a link:
<a href="$jslink.setAction($config.getString("action.logout"))"
$FontStyle>$l10n.TOP_LOGOUT</a>
but to get it to work in a tab is more challenging
I would try a redirect portlet with the URL set to:
http://localhost:8080/jetspeed/portal/media-type/html/user/admin/page/default.psml?action=JLogoutUser
although you may want to extend and create that at runtime
See the portlets.xreg:
<portlet-entry name="RedirectPortlet" hidden="false"
type="abstract" application="false">
<meta-info>
<title>Redirect Portlet</title>
<description>Redirects the portal to the configured URL
when associated with a Jetspeed menu.</description>
</meta-info>
<classname>org.apache.jetspeed.portal.portlets.RedirectPortlet</classname>
<parameter name="url"
value="http://localhost:8080/jetspeed/portal/media-type/html/user/admin/page/default.psml?action=JLogoutUser"
hidden="false" cachedOnName="true" cachedOnValue="true">
<meta-info>
<title>URL</title>
<description>Redirects a menu option to this
URL</description>
</meta-info>
</parameter>
Just don't put it on the first tab or it will log you out immediately!
Well, I'm trying to perform a similar task. A solution in my case is
rather simple, as 'logut' action is realized with redirecting to
something like 'http://localhost:8080/jetspeed/login/logout' (of
course, generate the URL dynamicaly, so that it points to your
portal's appropriate resource), which link can be placed anywhere,
even in a tab (by a decorator script).
The question was for 1.6, this is a 2.0 solution
By the way, I'm trying to title such a link as 'logout username' and
'not log-on' if none user is logged on. Is there any Jetspeed global
variable in Velocity storing a name (or other data) of a current
user? Or I should rather create it myself?
(this is off thread now, because im speaking of 2.0)
we don't store any user attributes in our tables
try getting it from the user attributes (which you will need to manage)
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]