[prev in list] [next in list] [prev in thread] [next in thread] 

List:       jetspeed-user
Subject:    RE: Getting userid and password
From:       "Richard Berger" <richard.berger () actiontech ! com>
Date:       2004-01-30 16:53:53
Message-ID: EA7BD8FBFE2B674D84722D3BFB3941FED5CF11 () fargo ! corp ! actiontech ! com
[Download RAW message or body]

Peter - 

You have probably already figured this out but something like the IframePortlet is \
what you want.  You can just plug in the URL of your jsp page and it will show up in \
the portal.

Enjoy,
RB 



Twenty Years | One Mission | Accelerating Business Processes 


Richard Berger 
Action Technologies, Inc. 
VP, Product Management 
510.748.1017 (Office) 
510.769.0596 (Fax) 
www.actiontech.com 

NOTE: The opinions expressed herein are those of the writer and not necessarily those \
                of Action Technologies, Inc. or its employees or its affiliates. 
-----Original Message-----
From: Richard Berger 
Sent: Wednesday, January 28, 2004 8:49 AM
To: Jetspeed Users List
Subject: RE: Getting userid and password

I believe you were thinking that the JSP portlet is something where you can just plug \
in the name of a JSP page and you are ready to go (kinda like the RSS portlet).  \
However, I don't think it works like that.  Reading from the tutorial - "there are \
two required parameters, the template and the action".  The template is your JSP and \
the action is the code that is used to gather the information that the page will use. \
I am guessing that you JSP doesn't require any "pre-processing", so you thought you \
could use the "standard" action - but as I said earlier, I don't think it works like \
that.  Going through the tutorial will give you the understanding you need to build \
your own portlet (it is not hard).  The tutorial is available at: \
http://www.bluesunrise.com/jetspeed-docs/JetspeedTutorial.htm (although the site \
seems to be down at this moment - usually it is fine).

Good luck,
RB 



Twenty Years | One Mission | Accelerating Business Processes 


Richard Berger
Action Technologies, Inc. 
VP, Product Management
510.748.1017 (Office)
510.769.0596 (Fax)
www.actiontech.com 

NOTE: The opinions expressed herein are those of the writer and not necessarily those \
                of Action Technologies, Inc. or its employees or its affiliates. 
-----Original Message-----
From: Peter Andersén [mailto:peter.andersen@internetborder.se]
Sent: Wednesday, January 28, 2004 5:37 AM
To: Jetspeed Users List
Subject: Re: Getting userid and password

Thanks
I tougth that jsp portlet was a portlet to execute JSP script do i need to produce my \
own portlet ??

Peter A

----- Original Message -----
From: "Richard Berger" <richard.berger@actiontech.com>
To: "Jetspeed Users List" <jetspeed-user@jakarta.apache.org>
Sent: Tuesday, January 27, 2004 7:29 PM
Subject: RE: Getting userid and password


Probably not the best person to try and answer this, but I will give it a shot....
Assuming that your portlet is a JSP portlet (the answer is similar if it is a \
Velocity portlet), one of the parameters you specify for that portlet is the name of \
the Action - which will be the class that will be called to handle the display of the \
portlet ("YourPortletAction" in the example below).  That is where the code would go.

I would suggest reviewing the tutorial and focusing on the chapter on the JSP Portlet \
(or Velocity Portlet) - that will give you the required background.

Good luck,
RB





Twenty Years | One Mission | Accelerating Business Processes


Richard Berger
Action Technologies, Inc.
VP, Product Management
510.748.1017 (Office)
510.769.0596 (Fax)
www.actiontech.com

NOTE: The opinions expressed herein are those of the writer and not necessarily those \
                of Action Technologies, Inc. or its employees or its affiliates.
-----Original Message-----
From: Peter Andersén [mailto:peter.andersen@internetborder.se]
Sent: Tuesday, January 27, 2004 6:15 AM
To: Jetspeed Users List
Subject: Re: Getting userid and password

Thanks
Could you just clarify some stuff since im very new to jetspeed.
What do you mean by actionclass it is in my bean or ??

Thanks
Peter

----- Original Message -----
From: "Bela Kovac" <wizard@uni-paderborn.de>
To: "Jetspeed Users List" <jetspeed-user@jakarta.apache.org>
Sent: Friday, January 23, 2004 8:44 PM
Subject: Re: Getting userid and password


Am 22.01.2004 um 21:51 schrieb Peter Andersén:

> Is there a method in the jsp page to get username and password on the 
> user logged in or ?

There is a way to get L and P from the user logged in (in a JSP
portlet):

The action class should look something like this:


package yourClassesInHere.modules.actions.portlets;

import org.apache.jetspeed.modules.actions.portlets.JspPortletAction;
import org.apache.jetspeed.portal.Portlet;
import org.apache.jetspeed.util.PortletSessionState;
import org.apache.turbine.util.RunData;

public class YourPortletAction extends JspPortletAction {
     protected void buildNormalContext(Portlet portlet, RunData rundata) {
         String uid    = (String) rundata.getUser().getUserName();
         String passwd = (String) rundata.getUser().getPassword();
         rundata.getRequest().setAttribute("passwd", passwd);
         rundata.getRequest().setAttribute("uid", uid);
     }
}


while in the corresponding .jsp there should be some lines like:


<%
String sUid        = (String) request.getAttribute("uid");
String sPasswd     = (String) request.getAttribute("passwd");
%>

UID: <%= sUid %><br>
PassWD: <%= sPasswd %>


Hope this helps.


Bela

--
"Der Blitzableiter auf einem Kirchturm ist das denkbar stärkste Misstrauensvotum \
                gegen den lieben Gott."
   -- Karl Kraus


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic