Author: husted
Date: Fri Mar 17 18:01:21 2006
New Revision: 386789
URL: http://svn.apache.org/viewcvs?rev=386789&view=rev
Log:
Action2 Apps
* Mailreader - Work in progress
Added:
struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html (with
props)
struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml (with
props)
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon-validation
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp
(with props)
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp
(with props)
Removed:
struts/sandbox/trunk/action2/apps/mailreader/src/java/Home.java
Modified:
struts/sandbox/trunk/action2/apps/mailreader/src/java/xwork.xml
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Welcome.jsp
Added: struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html?rev=386789&view=auto
==============================================================================
--- struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html (added)
+++ struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html Fri Mar 17
18:01:21 2006
@@ -0,0 +1,9 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<html>
+<head>
+<META HTTP-EQUIV="Refresh" CONTENT="0;URL=Home.jsp">
+</head>
+<body>
+<p>Loading ...</p>
+</body>
+</html>
Propchange: struts/sandbox/trunk/action2/apps/cookbook/src/webapp/index.html
------------------------------------------------------------------------------
svn:eol-style = native
Added: struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml?rev=386789&view=auto
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml (added)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml Fri Mar
17 18:01:21 2006
@@ -0,0 +1,12 @@
+<?xml version='1.0'?>
+<database>
+ <user username="user" fromAddress="[EMAIL PROTECTED]"
+ fullName="John Q. User" password="pass">
+ <subscription host="mail.hotmail.com" autoConnect="false"
+ password="bar" type="pop3" username="user1234">
+ </subscription>
+ <subscription host="mail.yahoo.com" autoConnect="false" password="foo"
+ type="imap" username="jquser">
+ </subscription>
+ </user>
+</database>
Propchange: struts/sandbox/trunk/action2/apps/mailreader/src/java/database.xml
------------------------------------------------------------------------------
svn:eol-style = native
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,235 @@
+/*
+ * $Id: Constants.java 360442 2005-12-31 20:10:04Z husted $
+ *
+ * Copyright 1999-2004 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package mailreader2;
+
+/**
+ * <p>
+ * Manifest constants for the MailReader application.
+ * </p>
+ *
+ * @version $Rev: 360442 $ $Date: 2005-12-31 15:10:04 -0500 (Sat, 31 Dec 2005)
$
+ */
+
+public final class Constants {
+
+ // --- Tokens ----
+
+ /**
+ * <p>
+ * The token representing a "create" task.
+ * </p>
+ */
+ public static final String CREATE = "Create";
+
+ /**
+ * <p>
+ * The application scope attribute under which our user database
+ * is stored.
+ * </p>
+ */
+ public static final String DATABASE_KEY = "database";
+
+ /**
+ * <p>
+ * The token representing a "edit" task.
+ * </p>
+ */
+ public static final String DELETE = "Delete";
+
+ /**
+ * <p>
+ * The token representing a "edit" task.
+ * </p>
+ */
+ public static final String EDIT = "Edit";
+
+ /**
+ * <p>
+ * The request attributes key under the WelcomeAction stores an ArrayList
+ * of error messages, if required resources are missing.
+ * </p>
+ */
+ public static final String ERROR_KEY = "ERROR";
+
+ /**
+ * <p>
+ * The token representing a "failure" result for this application.
+ * </p>
+ */
+ public static final String FAILURE = "Failure";
+
+ /**
+ * <p>
+ * The token representing a "logon" result for this application.
+ * </p>
+ */
+ public static final String LOGON = "Logon";
+
+ /**
+ * <p>
+ * The package name for this application.
+ * </p>
+ */
+ public static final String PACKAGE = "org.apache.struts.apps.mailreader";
+
+ /**
+ * <p>
+ * The token representing a "save" task.
+ * </p>
+ */
+ public static final String SAVE = "Save";
+
+ /**
+ * <p>
+ * The session scope attribute under which the Subscription object
+ * currently selected by our logged-in User is stored.
+ * </p>
+ */
+ public static final String SUBSCRIPTION_KEY = "subscription";
+
+ /**
+ * <p>
+ * The token representing a "success" result for this application.
+ * </p>
+ */
+ public static final String SUCCESS = "Success";
+
+ /**
+ * <p>
+ * The session scope attribute under which the User object
+ * for the currently logged in user is stored.
+ * </p>
+ */
+ public static final String USER_KEY = "user";
+
+ // ---- Error Messages ----
+
+ /**
+ * <p>
+ * A static message in case database resource is not loaded.
+ * <p>
+ */
+ public static final String ERROR_DATABASE_NOT_LOADED =
+ "ERROR: User database not loaded -- check servlet container logs
for error messages.";
+
+ /**
+ * <p>
+ * A static message in case message resource is not loaded.
+ * </p>
+ */
+ public static final String ERROR_MESSAGES_NOT_LOADED =
+ "ERROR: Message resources not loaded -- check servlet container
logs for error messages.";
+
+ // ---- Error Tokens ----
+
+ /**
+ * <p>
+ * The resource key for an error with the transactional token.
+ * </p>
+ */
+ public static final String MSG_TRANSACTION_TOKEN =
"error.transaction.token";
+
+ // ---- Log Messages ----
+
+ /**
+ * <p>
+ * The message to log when cancelling a transaction.
+ * </p>
+ */
+ public static final String LOG_CANCEL = " Transaction cancelled: ";
+
+ /**
+ * <p>
+ * The message to log when forwarding to a result.
+ * </p>
+ */
+ public static final String LOG_RESULT = " Forwarding to result: ";
+
+ /**
+ * <p>
+ * The message to log when forwarding to a 'failure' result.
+ * <p>
+ */
+ public static final String LOG_FAILURE = LOG_RESULT + FAILURE;
+
+ /**
+ * <p>
+ * The message to log when forwarding to a 'logon' result.
+ * </p>
+ */
+ public static final String LOG_LOGON = LOG_RESULT + LOGON;
+
+ /**
+ * <p>
+ * The message to log when populating a form.
+ * </p>
+ */
+ public static final String LOG_POPULATE_FORM = " Populating form from: ";
+
+ /**
+ * <p>
+ * The message to log when populating a subscription.
+ * </p>
+ */
+ public static final String LOG_POPULATE_SUBSCRIPTION = " Populating
subscription: ";
+
+ /**
+ * <p>
+ * The message to log when populating a user.
+ * </p>
+ */
+ public static final String LOG_POPULATE_USER = " Populating user: ";
+
+ /**
+ * <p>
+ * The message to log when forwarding to a 'success' result.
+ * </p>
+ */
+ public static final String LOG_PROCESSING = " Processing: ";
+
+ /**
+ * <p>
+ * The message to log when forwarding to a 'success' result.
+ * </p>
+ */
+ public static final String LOG_SUCCESS = LOG_RESULT + SUCCESS;
+
+ /**
+ * <p>
+ * The message to log when setting a transactional token.
+ * </p>
+ */
+ public static final String LOG_TOKEN = " Setting transactional control
token";
+
+ /**
+ * <p>
+ * The message to log when checking a transactional token.
+ * </p>
+ */
+ public static final String LOG_TOKEN_CHECK = " Checking transactional
control token";
+
+ /**
+ * <p>
+ * Message to log if saving a user fails.
+ * </p>
+ */
+ public static final String LOG_DATABASE_SAVE_ERROR = " Unexpected error
when saving User: ";
+
+
+}
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Constants.java
------------------------------------------------------------------------------
svn:eol-style = native
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon-validation
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon-validation?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon-validation
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon-validation
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,14 @@
+<!DOCTYPE validators PUBLIC "-//OpenSymphony Group//XWork Validator 1.0.2//EN"
"http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
+
+<validators>
+ <field name="username">
+ <field-validator type="requiredstring">
+ <message>You must enter a username</message>
+ </field-validator>
+ </field>
+ <field name="password">
+ <field-validator type="requiredstring">
+ <message>You must enter a password</message>
+ </field-validator>
+ </field>
+</validators>
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,98 @@
+/*
+ * $Id: LogonAction.java 360442 2005-12-31 20:10:04Z husted $
+ *
+ * Copyright 2000-2004 Apache Software Foundation
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package mailreader2;
+
+import org.apache.struts.apps.mailreader.dao.User;
+/**
+ * <p>
+ * Validate a user logon.
+ * </p>
+ *
+ * @version $Rev: 360442 $ $Date: 2005-12-31 15:10:04 -0500 (Sat, 31 Dec 2005)
$
+ */
+public final class Logon extends MailreaderSupport {
+
+ // --------------------------------------------------------------
Properties
+
+ /**
+ * <p>The password input field.</p>
+ */
+ private String password = null;
+
+
+ /**
+ * @return Returns the password.
+ */
+ public String getPassword() {
+ return this.password;
+ }
+
+ /**
+ * @param password The password to set.
+ */
+ public void setPassword(String password) {
+ this.password = password;
+ }
+
+ /**
+ * <p>The username input field.</p>
+ */
+ private String username = null;
+
+
+ /**
+ * @return Returns the username.
+ */
+ public String getUsername() {
+ return this.username;
+ }
+
+ /**
+ * @param username The username to set.
+ */
+ public void setUsername(String username) {
+ this.username = username;
+ }
+
+ /**
+ * <p>
+ * Use "username" and "password" fields to retrieve a User
+ * object from the database. If credentials are not valid, or database
+ * has disappeared, post error messages and forward to input.
+ * </p>
+ *
+ * @throws Exception if the application business logic throws
+ * an exception
+ */
+ public String execute() throws Exception {
+
+ // Retrieve user
+ User user = doGetUser(username, password);
+
+ // Report back any errors, and exit if any
+ // FIXME: if (!errors.isEmpty()) { this.saveErrors(request, errors);
return (mapping.getInputForward());
+
+ // Cache user object in session to signify logon
+ doCacheUser(user);
+
+ // Done
+ return SUCCESS;
+
+ }
+
+}
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/Logon.java
------------------------------------------------------------------------------
svn:eol-style = native
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,234 @@
+/*
+ * $Id: BaseAction.java 360442 2005-12-31 20:10:04Z husted $
+ *
+ * Copyright 1999-2004 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package mailreader2;
+
+import javax.servlet.ServletException;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import com.opensymphony.xwork.ActionSupport;
+import com.opensymphony.webwork.interceptor.SessionAware;
+import org.apache.struts.apps.mailreader.dao.User;
+import org.apache.struts.apps.mailreader.dao.Subscription;
+import org.apache.struts.apps.mailreader.dao.ExpiredPasswordException;
+import org.apache.struts.apps.mailreader.dao.UserDatabase;
+
+import java.util.Map;
+
+/**
+ * <p>
+ * Base Action for MailreaderSupport application.
+ * </p><p>
+ * All the BaseAction helper methods are prefixed with "do"
+ * so that they can be easily distinguished from Struts and Servlet API
methods.
+ * BaseAction subclasses may also have prive "do" helpers of their own.
+ * </p><p>
+ * Methods are kept in alphabetical order, to make them easier to find.
+ * </p>
+ *
+ * @version $Rev: 360442 $ $Date: 2005-12-31 15:10:04 -0500 (Sat, 31 Dec 2005)
$
+ */
+public abstract class MailreaderSupport extends ActionSupport implements
SessionAware {
+
+ // ---- SessionAware ----
+
+ private Map session;
+
+ public void setSession(Map session) {
+ this.session = session;
+ }
+
+ public Map getSession() {
+ return session;
+ }
+
+ // ---- Fields ----
+
+ /**
+ * <p>
+ * Name of username field ["username"].
+ * </p>
+ */
+ public static String USERNAME = "username";
+
+ /**
+ * <p>
+ * Name of password field ["password"].
+ * </p>
+ */
+ public static String PASSWORD = "password";
+
+ /**
+ * <p>
+ * Name of task field ["task"].
+ * </p>
+ */
+ public final static String TASK = "task";
+
+ // ---- Protected Methods ----
+
+ /**
+ * <p>
+ * Store User object in client session.
+ * If user object is null, any existing user object is removed.
+ * </p>
+ *
+ * @param user The user object returned from the database
+ */
+ void doCacheUser(User user) {
+ getSession().put(Constants.USER_KEY, user);
+ }
+
+ /**
+ * <p>
+ * Helper method to log event and cancel transaction.
+ * </p>
+ *
+ * @param method Method being processed
+ * @param key Attrkibute to remove from session, if any
+ */
+ protected void doCancel(String method, String key) {
+ if (key != null) {
+ getSession().remove(key);
+ }
+ }
+
+ /**
+ * <p>
+ * Obtain the cached Subscription object, if any.
+ * </p>
+ *
+ * @return Cached Subscription object or null
+ */
+ protected Subscription doGetSubscription() {
+ return (Subscription) getSession().get(Constants.SUBSCRIPTION_KEY);
+ }
+
+ /**
+ * <p>
+ * Confirm user credentials. Post any errors and return User object
+ * (or null).
+ * </p>
+ *
+ * @param database Database in which to look up the user
+ * @param username Username specified on the logon form
+ * @param password Password specified on the logon form
+ * @return Validated User object or null
+ * @throws org.apache.struts.apps.mailreader.dao.ExpiredPasswordException
+ * to be handled by Struts exception
+ * processor via the action-mapping
+ */
+ User doGetUser(UserDatabase database, String username,
+ String password)
+ throws ExpiredPasswordException {
+
+ User user = null;
+ if (database == null) {
+ // FIXME: errors.add( ActionMessages.GLOBAL_MESSAGE, new
ActionMessage("error.database.missing"));
+ } else {
+
+ if (username.equals("Hermes")) {
+ throw new ExpiredPasswordException("Hermes");
+ }
+
+ user = database.findUser(username);
+ if ((user != null) && !user.getPassword().equals(password)) {
+ user = null;
+ }
+ if (user == null) {
+ // FIXME: errors.add(ActionMessages.GLOBAL_MESSAGE, new
ActionMessage("error.password.mismatch"));
+ }
+ }
+
+ return user;
+ }
+
+ /**
+ * <p>
+ * Confirm user credentials. Post any errors and return User object
+ * (or null).
+ * </p>
+ *
+ * @param username Username specified on the logon form
+ * @param password Password specified on the logon form
+ * @return Validated User object or null
+ * @throws org.apache.struts.apps.mailreader.dao.ExpiredPasswordException
+ * to be handled by Struts exception
+ * processor via the action-mapping
+ */
+ User doGetUser(String username,
+ String password)
+ throws ExpiredPasswordException {
+
+ return doGetUser(doGetUserDatabase(), username, password);
+ }
+
+ /**
+ * <p>
+ * Return a reference to the UserDatabase
+ * or null if the database is not available.
+ * </p>
+ *
+ * @return a reference to the UserDatabase or null if the database is not
+ * available
+ */
+ protected UserDatabase doGetUserDatabase() {
+ return (UserDatabase) getSession().get(Constants.DATABASE_KEY);
+ }
+
+ /**
+ * <p>
+ * Helper method to obtain User form session (if any).
+ * </p>
+ *
+ * @return User object, or null if there is no user.
+ */
+ protected User doGetUser() {
+ return (User) getSession().get(Constants.USER_KEY);
+ }
+
+ /**
+ * <p>
+ * The <code>Log</code> instance for this application.
+ * </p>
+ */
+ protected Log log = LogFactory.getLog(Constants.PACKAGE);
+
+ /**
+ * <p>
+ * Persist the User object, including subscriptions, to the database.
+ * </p>
+ *
+ * @param user Our User object
+ * @throws javax.servlet.ServletException On any error
+ */
+ protected void doSaveUser(User user) throws ServletException {
+
+ try {
+ UserDatabase database = doGetUserDatabase();
+ database.save();
+ } catch (Exception e) {
+ String message = Constants.LOG_DATABASE_SAVE_ERROR +
user.getUsername();
+ log.error(message, e);
+ throw new ServletException(message, e);
+ }
+ }
+
+}
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/java/mailreader2/MailreaderSupport.java
------------------------------------------------------------------------------
svn:eol-style = native
Modified: struts/sandbox/trunk/action2/apps/mailreader/src/java/xwork.xml
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/java/xwork.xml?rev=386789&r1=386788&r2=386789&view=diff
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/java/xwork.xml (original)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/java/xwork.xml Fri Mar 17
18:01:21 2006
@@ -11,7 +11,31 @@
<result>/pages/Welcome.jsp</result>
</action>
- <!-- Add your actions here -->
+ <action name="Logon"
+ class="mailreader2.Logon">
+ <exception-mapping
+
exception="org.apache.struts.apps.mailreader.dao.ExpiredPasswordException"
+ result="expired"/>
+ <result name="input">/pages/Logon.jsp</result>
+ <result name="expired" type="chain">Password!input</result>
+ <result>/pages/MainMenu.jsp</result>
+ </action>
+ <action name="Password">
+ <result name="input">/pages/ChangePassword.jsp</result>
+ </action>
+
+ <action name="MainMenu">
+ <result>/pages/MainMenu.jsp</result>
+ </action>
+
+ <action name="Registration">
+ <result name="edit">/pages/Registration.jsp</result>
+ </action>
+
+ <action name="Logoff">
+ <result type="chain">MainMenu</result>
+ </action>
+
</package>
</xwork>
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,16 @@
+<[EMAIL PROTECTED] uri="/webwork" prefix="ww" %>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+ <head>
+ <title><ww:text name="change.title"/></title>
+ <link href="<ww:url value="/css/mailreader.css"/>" rel="stylesheet"
type="text/css" />
+ </head>
+ <body>
+
+ <ww:text name="change.message"/>
+ <a href="<ww:url action="Logon"/>">
+ <ww:text name="change.try"/>
+ </a>
+
+ </body>
+</html>
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/ChangePassword.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Added: struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp?rev=386789&view=auto
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp
(added)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,5 @@
+<[EMAIL PROTECTED] uri="/webwork" prefix="ww" %>
+<hr/>
+<p>
+<a href="<ww:url action="Welcome" />"><ww:text name="index.title"/></a>
+</p>
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Footer.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Added: struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp?rev=386789&view=auto
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp
(added)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp Fri
Mar 17 18:01:21 2006
@@ -0,0 +1,26 @@
+<[EMAIL PROTECTED] uri="/webwork" prefix="ww" %>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <title><ww:text name="logon.title"/></title>
+ <link href="<ww:url value="/css/mailreader.css"/>" rel="stylesheet"
type="text/css" />
+</head>
+
+<body>
+
+<ww:form action="Logon" method="POST">
+ <table border="0" width="100%">
+
+ <ww:textfield label="%{getText('prompt.username'}" name="username"
size="16" maxlength="18"/>
+
+ <ww:textfield label="%{getText('prompt.password'}" name="password"
size="16" maxlength="18"/>
+
+ <ww:submit />
+
+ </table>
+
+</ww:form>
+
+<jsp:include page="Footer.jsp"/>
+</body>
+</html>
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Logon.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp?rev=386789&view=auto
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp
(added)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,22 @@
+<[EMAIL PROTECTED] uri="/webwork" prefix="ww" %>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <title><ww:text name="mainMenu.title"/></title>
+ <link rel="stylesheet" type="text/css" href="base.css"/>
+</head>
+
+<body>
+<h3><ww:text name="mainMenu.heading"/> <bean:write name="user"
+
property="fullName"/></h3>
+<ul>
+ <li><a href="<ww:url action="Registration!edit" />">
+ <ww:text name="mainMenu.registration" />
+ </a>
+ </li>
+ <li><a href="<ww:url action="Loggoff"/>">
+ <ww:text name="mainMenu.logoff" />
+ </a>
+</ul>
+</body>
+</html>
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/MainMenu.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Added:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp?rev=386789&view=auto
==============================================================================
---
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp
(added)
+++
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp
Fri Mar 17 18:01:21 2006
@@ -0,0 +1,5 @@
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+<html>
+ <head><title>Simple jsp page</title></head>
+ <body>Place your content here</body>
+</html>
\ No newline at end of file
Propchange:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Registration.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Modified:
struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Welcome.jsp
URL:
http://svn.apache.org/viewcvs/struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Welcome.jsp?rev=386789&r1=386788&r2=386789&view=diff
==============================================================================
--- struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Welcome.jsp
(original)
+++ struts/sandbox/trunk/action2/apps/mailreader/src/webapp/pages/Welcome.jsp
Fri Mar 17 18:01:21 2006
@@ -10,8 +10,8 @@
<h3><ww:text name="index.heading"/></h3>
<ul>
- <li><a href="<ww:url action="EditRegistration"/>"><ww:text
name="index.registration"/></a></li>
- <li><a href="<ww:url action="Logon"/>"><ww:text
name="index.logon"/></a></li>
+ <li><a href="<ww:url action="Registration!edit"/>"><ww:text
name="index.registration"/></a></li>
+ <li><a href="<ww:url action="Logon!input"/>"><ww:text
name="index.logon"/></a></li>
</ul>
<h3>Language Options</h3>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]