You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Steve Davis <st...@digitalevergreen.com> on 2001/07/06 18:30:18 UTC
RE: Simple question I hope
The way I do it is to get the RunData object in the default.jsp
and then check to see if the user is logged in. If they are not
then I show the Login screen. I.E
<%@ import page = "org.apache.turbine.util.RunData" %>
.
.
.
<% RunData rdata = (RunData) request.getAttribute("rundata"); %>
<% if ( rdata.getUser().hasLoggedIn() ) { %>
Do something
<% } else { %>
get login screen
<% } %>
-- Steve Davis
-----Original Message-----
From: Anthony Smith [mailto:anthony.smith@fedex.com]
Sent: Thursday, July 05, 2001 5:03 PM
To: jetspeed-dev@jakarta.apache.org
Subject: Simple question I hope
I am new to JETSPEED but I have a quick question.
Once I access Jetspeed at:: http://localhost:8080/jetspeed/
How do I change from the starting page that asks me to log on to just
going straight to the log on.
I know that the first page is (in my case)
c:\jakarta-tomcat-3.2.2\webapps\jetspeed\WEB_INF\templates\jsp\layouts\h
tml\default.jsp
which is this file:
<%@ taglib uri='../../tld/template.tld' prefix='jetspeed' %>
<html>
<!-- Jetspeed JSP Layout <a
href="mailto:ingo@raleigh.ibm.com">Ingo Schuster</a> -->
<head>
<base href="<jetspeed:uriLookup type="BaseURL" />">
<link href="css/default.css" type="text/css" rel="stylesheet">
</head>
<body bgcolor="#ffffff">
<table cellspacing="0" width="100%" border="0" cellpadding="0">
<tr>
<td>
<img src="<jetspeed:contentUri href="images/FedExCorpLogo.gif" />">
</td>
<td>
<jetspeed:jetspeedNavigation defaultTemplate="top_default.jsp"
loggedInTemplate="top_loggedIn.jsp" />
</td>
</tr>
</table>
<table cellspacing="0" width="100%" cellpadding="0" border="0">
<tr>
<td valign="top" bgcolor="#ffffff">
<jetspeed:jetspeedNavigation defaultTemplate="left.jsp" />
<jetspeed:ecsscreen />
</td>
</tr>
</table>
<table cellspacing="0" width="100%" cellpadding="0" border="0">
<tr>
<td valign="bottom" bgcolor="#ffffff">
<jetspeed:jetspeedNavigation defaultTemplate="bottom.jsp" />
</td>
</tr>
</table>
</body>
</html>
********************
I just want to be able to go straight to the login screen in order to
type in my user id and password
with out getting that other screen.
I think that this snippet has something to do with it:
<jetspeed:ecsscreen />
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-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
Re: Simple question I hope
Posted by Raphaël Luta <ra...@networks.groupvu.com>.
sbelt wrote:
> Or simply add a loginPortlet to the top-left of your default page. Makes
> your login page alot more interesting/useful.
>
> I have not downloaded the latest CVS, but such a portlet use to exist as an
> example of a Turbine Portlet.
>
Still there... but I've never found the time to wonder how to artfully include
it in the main page.
Any volunteers ? :)
--
Raphael Luta - raphael.luta@networks.groupvu.com
Vivendi Universal Networks - Paris
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org
Re: Simple question I hope
Posted by sbelt <sb...@velos.com>.
Or simply add a loginPortlet to the top-left of your default page. Makes
your login page alot more interesting/useful.
I have not downloaded the latest CVS, but such a portlet use to exist as an
example of a Turbine Portlet.
Steve B.
----- Original Message -----
From: "Raphaël Luta" <ra...@networks.groupvu.com>
To: <je...@jakarta.apache.org>
Sent: Friday, July 06, 2001 9:42 AM
Subject: Re: Simple question I hope
> Steve Davis wrote:
>
> > The way I do it is to get the RunData object in the default.jsp
> > and then check to see if the user is logged in. If they are not
> > then I show the Login screen. I.E
> >
> > <%@ import page = "org.apache.turbine.util.RunData" %>
> > .
> > .
> > .
> > <% RunData rdata = (RunData) request.getAttribute("rundata"); %>
> > <% if ( rdata.getUser().hasLoggedIn() ) { %>
> > Do something
> > <% } else { %>
> > get login screen
> > <% } %>
> >
> > -- Steve Davis
> >
>
>
> The proper way is to write your own SessionValidator action which
> requires login before displaying the home page (you can check out the
> default Turbine sessionValidator as an example).
>
> Template logic is bad ! Use actions for the controller part of MVC.
> This is probably the main strength of Turbine.
>
> --
> Raphael Luta - raphael.luta@networks.groupvu.com
> Vivendi Universal Networks - Paris
>
>
> ---------------------------------------------------------------------
> 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
Re: Simple question I hope
Posted by Raphaël Luta <ra...@networks.groupvu.com>.
Steve Davis wrote:
> The way I do it is to get the RunData object in the default.jsp
> and then check to see if the user is logged in. If they are not
> then I show the Login screen. I.E
>
> <%@ import page = "org.apache.turbine.util.RunData" %>
> .
> .
> .
> <% RunData rdata = (RunData) request.getAttribute("rundata"); %>
> <% if ( rdata.getUser().hasLoggedIn() ) { %>
> Do something
> <% } else { %>
> get login screen
> <% } %>
>
> -- Steve Davis
>
The proper way is to write your own SessionValidator action which
requires login before displaying the home page (you can check out the
default Turbine sessionValidator as an example).
Template logic is bad ! Use actions for the controller part of MVC.
This is probably the main strength of Turbine.
--
Raphael Luta - raphael.luta@networks.groupvu.com
Vivendi Universal Networks - Paris
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-user-help@jakarta.apache.org