jspwiki-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ajaqu...@apache.org
Subject svn commit: r724022 - in /incubator/jspwiki/trunk: ./ src/com/ecyrd/jspwiki/ src/com/ecyrd/jspwiki/action/ src/com/ecyrd/jspwiki/tags/ src/com/ecyrd/jspwiki/ui/migrator/ src/webdocs/ src/webdocs/admin/ src/webdocs/templates/default/ src/webdocs/templat...
Date Sat, 06 Dec 2008 18:22:54 GMT
Author: ajaquith
Date: Sat Dec  6 10:22:53 2008
New Revision: 724022

URL: http://svn.apache.org/viewvc?rev=724022&view=rev
Log:
Small tweaks to JspMigrator to look for, and fix, JSP page import directives for TextUtil,
FileUtil and SearchResult (these have moved). Fixed JspMigrator Ant task ("migrate") so that
it runs. Minor JSP tweaks so they compile again.

Added:
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/AbstractPageActionBean.java
Modified:
    incubator/jspwiki/trunk/ChangeLog
    incubator/jspwiki/trunk/build.xml
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/EditActionBean.java
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/ViewActionBean.java
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/tags/SearchResultIteratorInfo.java
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JSPWikiJspTransformer.java
    incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JspDocument.java
    incubator/jspwiki/trunk/src/webdocs/Captcha.jsp
    incubator/jspwiki/trunk/src/webdocs/Comment.jsp
    incubator/jspwiki/trunk/src/webdocs/Edit.jsp
    incubator/jspwiki/trunk/src/webdocs/Error.jsp
    incubator/jspwiki/trunk/src/webdocs/Message.jsp
    incubator/jspwiki/trunk/src/webdocs/PageModified.jsp
    incubator/jspwiki/trunk/src/webdocs/Rename.jsp
    incubator/jspwiki/trunk/src/webdocs/Search.jsp
    incubator/jspwiki/trunk/src/webdocs/admin/Admin.jsp
    incubator/jspwiki/trunk/src/webdocs/admin/SecurityConfig.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXPreview.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXSearch.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/AttachmentTab.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/EditGroupContent.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/GroupContent.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/InfoContent.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/NewGroupContent.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/PageTab.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/editors/FCK.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/editors/plain.jsp
    incubator/jspwiki/trunk/src/webdocs/templates/default/editors/preview.jsp

Modified: incubator/jspwiki/trunk/ChangeLog
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/ChangeLog?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/ChangeLog (original)
+++ incubator/jspwiki/trunk/ChangeLog Sat Dec  6 10:22:53 2008
@@ -1,3 +1,11 @@
+2008-12-06  Andrew Jaquith <ajaquith AT apache DOT org>
+
+        * 3.0.0-svn-26
+
+        * Small tweaks to JspMigrator to look for, and fix, JSP page import directives
+        for TextUtil, FileUtil and SearchResult (these have moved). Fixed JspMigrator
+        Ant task ("migrate") so that it runs. Minor JSP tweaks so they compile again.
+
 2008-12-05  Andrew Jaquith <ajaquith AT apache DOT org>
 
         * 3.0.0-svn-25
@@ -71,7 +79,7 @@
         * 3.0.0-svn-18
 
         * Checked in the Stripes code (about 220 classes, tests, JSPs
-        and other files. All code compiles clean, but the JSPs do NOT
+        and other files). All code compiles clean, but the JSPs do NOT
         work at the moment. Unit tests run clean except for some
         stray failing Stripes-related unit tests. See the file
         doc/README - Stripes Migration for some (repeat, SOME) details

Modified: incubator/jspwiki/trunk/build.xml
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/build.xml?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/build.xml (original)
+++ incubator/jspwiki/trunk/build.xml Sat Dec  6 10:22:53 2008
@@ -300,7 +300,7 @@
       <arg line="${srcfiles}"/>
     </exec>
     <!-- Migrate the JSPs -->
-    <java classname="com.ecyrd.jspwiki.ui.stripes.JspMigrator" fork="yes" maxmemory="512m">
+    <java classname="com.ecyrd.jspwiki.ui.migrator.JspMigrator" fork="yes" maxmemory="512m">
       <classpath>
          <path refid="path.tests" />
       </classpath>

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/Release.java Sat Dec  6 10:22:53 2008
@@ -77,7 +77,7 @@
      *  <p>
      *  If the build identifier is empty, it is not added.
      */
-    public static final String     BUILD         = "24";
+    public static final String     BUILD         = "26";
     
     /**
      *  This is the generic version string you should use

Added: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/AbstractPageActionBean.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/AbstractPageActionBean.java?rev=724022&view=auto
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/AbstractPageActionBean.java (added)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/AbstractPageActionBean.java Sat Dec
 6 10:22:53 2008
@@ -0,0 +1,41 @@
+package com.ecyrd.jspwiki.action;
+
+import net.sourceforge.stripes.validation.Validate;
+
+import com.ecyrd.jspwiki.WikiPage;
+
+/**
+ * Abstract WikiActionBean subclass used by all ActionBeans that use and process
+ * WikiPages using the <code>page</code> request parameter. In particular, this
+ * subclass contains special processing logic that sets the page property
+ * of the underlying {@link WikiActionBeanContext} when the {@link #setPage(WikiPage)}
+ * method is called by the Stripes controller.
+ */
+public class AbstractPageActionBean extends AbstractActionBean
+{
+    protected WikiPage m_page = null;
+    
+    /**
+     * Returns the WikiPage; defaults to <code>null</code>.
+     * @return the page
+     */
+    public WikiPage getPage()
+    {
+        return m_page;
+    }
+
+    /**
+     * Sets the WikiPage property for this ActionBean, and also
+     * sets the WikiActionBeanContext's page property to the same
+     * value by calling
+     * {@link com.ecyrd.jspwiki.ui.stripes.WikiActionBeanContext#setPage(WikiPage)}.
+     * @param page the wiki page.
+     */
+    @Validate( required = false)
+    public void setPage( WikiPage page )
+    {
+        m_page = page;
+        getContext().setPage( page );
+    }
+    
+}

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/EditActionBean.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/EditActionBean.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/EditActionBean.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/EditActionBean.java Sat Dec  6 10:22:53
2008
@@ -7,7 +7,7 @@
 import com.ecyrd.jspwiki.ui.stripes.WikiRequestContext;
 
 @UrlBinding("/Edit.jsp")
-public class EditActionBean extends AbstractActionBean
+public class EditActionBean extends AbstractPageActionBean
 {
     @DefaultHandler
     @HandlesEvent("edit")

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/ViewActionBean.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/ViewActionBean.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/ViewActionBean.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/action/ViewActionBean.java Sat Dec  6 10:22:53
2008
@@ -23,11 +23,9 @@
  *
  */
 @UrlBinding("/Wiki.action")
-public class ViewActionBean extends AbstractActionBean
+public class ViewActionBean extends AbstractPageActionBean
 {
     private Logger log = LoggerFactory.getLogger(ViewActionBean.class);
-    
-    private WikiPage m_page = null;
 
     public ViewActionBean()
     {
@@ -35,15 +33,6 @@
     }
 
     /**
-     * Returns the WikiPage; defaults to <code>null</code>.
-     * @return the page
-     */
-    public WikiPage getPage()
-    {
-        return m_page;
-    }
-
-    /**
      * <p>After the binding and validation  {@link LifecycleStage#BindingAndValidation}
      * lifecycle stage executes, this method determines whether the
      * page name specified in the request is actually a special page and
@@ -92,6 +81,10 @@
             {
                 // Bind the front page to the action bean
                 page = engine.getPage( engine.getFrontPage() );
+                if ( page == null )
+                {
+                    page = new WikiPage( engine, engine.getFrontPage() );
+                }
                 setPage(page);
                 return null;
             }
@@ -130,17 +123,6 @@
     }
 
     /**
-     * Sets the page.
-     * @param page the wiki page.
-     */
-    @Validate( required = false)
-    public void setPage( WikiPage page )
-    {
-        m_page = page;
-        getContext().setPage( page );
-    }
-    
-    /**
      * Default handler that simply forwards the user back to the same page. 
      * Every ActionBean needs a default handler to function properly, so we use
      * this (very simple) one.

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/tags/SearchResultIteratorInfo.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/tags/SearchResultIteratorInfo.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/tags/SearchResultIteratorInfo.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/tags/SearchResultIteratorInfo.java Sat Dec
 6 10:22:53 2008
@@ -34,7 +34,7 @@
     public VariableInfo[] getVariableInfo(TagData data)
     {
         VariableInfo[] var = { new VariableInfo( data.getAttributeString("id"),
-                                                 "com.ecyrd.jspwiki.SearchResult",
+                                                 "com.ecyrd.jspwiki.search.SearchResult",
                                                  true,
                                                  VariableInfo.NESTED )
         };

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JSPWikiJspTransformer.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JSPWikiJspTransformer.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JSPWikiJspTransformer.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JSPWikiJspTransformer.java Sat
Dec  6 10:22:53 2008
@@ -10,7 +10,10 @@
 import com.ecyrd.jspwiki.WikiContext;
 import com.ecyrd.jspwiki.action.WikiActionBean;
 import com.ecyrd.jspwiki.action.WikiContextFactory;
+import com.ecyrd.jspwiki.search.SearchResult;
 import com.ecyrd.jspwiki.ui.stripes.HandlerInfo;
+import com.ecyrd.jspwiki.util.FileUtil;
+import com.ecyrd.jspwiki.util.TextUtil;
 
 /**
  * Transforms a JspDocument from standard JSP markup to Stripes markup.
@@ -154,11 +157,54 @@
                     message( node, "Changed WikiContext.findContext() statement to WikiContextFactory.findContext()."
);
 
                     // Make sure we have a page import statement!
-                    List<Tag> imports = doc.getPageImport( WikiContextFactory.class.getName()
);
-                    if( imports.size() == 0 )
+                    doc.addPageImportDirective( WikiContextFactory.class );
+                }
+                
+            }
+            
+            // Make sure we have imports for any classes that moved
+            verifyImports( doc, SearchResult.class, FileUtil.class, TextUtil.class );
+            
+        }
+    }
+
+    /**
+     * Verifies that JSP page imports are available for a variable array of Classes.
+     * If a class does not have a corresponding import (either for the class
+     * specifically or for its enclosing package), one will be added.
+     * @param doc the JspDocument to check
+     * @param clazzes the classes to verify imports for
+     */
+    private void verifyImports( JspDocument doc, Class... clazzes )
+    {
+        // Build the regex Pattern to search for, and a lookup Map
+        Map<String,Class> classNames = new HashMap<String,Class>();
+        StringBuilder s = new StringBuilder();
+        s.append( '(' );
+        for ( Class clazz : clazzes )
+        {
+            classNames.put( clazz.getSimpleName(), clazz );
+            s.append( clazz.getSimpleName() );
+            s.append( '|' );
+        }
+        s.deleteCharAt( s.length() - 1 );
+        s.append( ')' );
+        Pattern searchPattern = Pattern.compile( s.toString() );
+
+        // Iterate through each script node and look for the classes that match
+        List<Node> nodes = doc.getScriptNodes();
+        for ( Node node : nodes )
+        {
+            Matcher m = searchPattern.matcher( node.getValue() );
+            while( m.find() )
+            {
+                String found= m.group( 1 ).trim();
+                Class foundClass = classNames.get( found );
+                if ( foundClass != null )
+                {
+                    if ( doc.addPageImportDirective( foundClass ) )
                     {
-                        doc.addPageImportDirective( WikiContextFactory.class.getName() );
-                        message( node, "Added page import for WikiContextFactory." );
+                        message( node, "Added page import for " + foundClass + "." );
                     }
                 }
             }

Modified: incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JspDocument.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JspDocument.java?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JspDocument.java (original)
+++ incubator/jspwiki/trunk/src/com/ecyrd/jspwiki/ui/migrator/JspDocument.java Sat Dec  6
10:22:53 2008
@@ -33,6 +33,57 @@
         visitChildren( allNodes, root.getChildren() );
         return Collections.unmodifiableList( allNodes );
     }
+    
+    /**
+     * Returns a list of nodes contained in the JspDocument that contain Java
+     * code, in the order parsed (depth-first search). Nodes that are of type
+     * {@link NodeType#JSP_DECLARATION}, {@link NodeType#SCRIPTLET},
+     * {@link NodeType#JSP_EXPRESSION} or {@link NodeType#CDATA} are considered
+     * to contain Java code. Attributes contained within Tags that are JSP expressions
+     * are also returned. The list returned is a defensive copy of the
+     * internally cached list.
+     * 
+     * @return the list of nodes
+     */
+    public List<Node> getScriptNodes()
+    {
+        List<Node> scriptNodes = new ArrayList<Node>();
+        List<Node> nodes = getNodes();
+        for ( Node node : nodes )
+        {
+            switch ( node.getType() )
+            {
+                case CDATA:
+                case JSP_DECLARATION:
+                case JSP_EXPRESSION:
+                case SCRIPTLET:
+                {
+                    scriptNodes.add( node );
+                    break;
+                }
+                case START_TAG:
+                case EMPTY_ELEMENT_TAG:
+                {
+                    Tag tag = (Tag)node;
+                    for ( Attribute attribute : tag.getAttributes() )
+                    {
+                        if ( attribute.getType() == NodeType.ATTRIBUTE )
+                        {
+                            for ( Node attributeNode : attribute.getChildren() )
+                            {
+                                if ( attributeNode.getType() == NodeType.JSP_EXPRESSION )
+                                {
+                                    scriptNodes.add( attributeNode );
+                                }
+                            }
+                        }
+                    }
+                    break;
+                }
+            }
+        }
+        return scriptNodes;
+    }
 
     /**
      * Returns the list of nodes contained in the JspDocument, of a specified
@@ -55,15 +106,26 @@
     }
 
     /**
-     * Convenience method that inserts a page-import directive after the last
-     * directive in the document.
-     * 
-     * @param type the type to add, <em>e.g.,</em> <code>org.foo.Bar</code>
+     * Convenience method that inserts a page-import directive for a supplied class
+     * after the last directive in the document. If an import directive already exists
+     * for this class (or for its containing package), it is not added.
+     *
+     * @param clazz the type to add, <em>e.g.,</em> <code>org.foo.Bar</code>
      *            or <code>org.foo.*</code>
+     *  @return <code>true</code> if an import was actually added, <code>false</code>
+     *  otherwise
      */
-    public void addPageImportDirective( String type )
+    public boolean addPageImportDirective( Class clazz )
     {
+        // No need to add it if it's already there
+        List<Tag> imports = getPageImport( clazz );
+        if( imports.size() > 0 )
+        {
+            return false;
+        }
+        
         // Create new directive
+        String type = clazz.getName();
         Tag directive = new Tag( this, NodeType.JSP_DIRECTIVE );
         directive.setName( "page" );
         directive.addAttribute( new Attribute( this, "import", type ) );
@@ -86,7 +148,7 @@
             lastDirective.addSibling( directive );
             lastDirective.addSibling( linebreak );
         }
-
+        return true;
     }
 
     /**
@@ -139,15 +201,16 @@
      * <li>&lt;%@ page import="org.bar.*" %&gt;</li>
      * </ul>
      * 
-     * @param type the class, interface or other type to match
+     * @param clazz the class, interface or other type to match
      * @return a list of all matching tags, which may be a zero-length list
      */
-    public List<Tag> getPageImport( String type )
+    public List<Tag> getPageImport( Class clazz )
     {
-        if( type == null )
+        if( clazz == null )
         {
-            throw new IllegalArgumentException( "Type cannot be null." );
+            throw new IllegalArgumentException( "Class cannot be null." );
         }
+        String type = clazz.getName();
         int periodPosition = type.lastIndexOf( '.' );
         String wildcardType = periodPosition == -1 ? "*" : type.substring( 0, periodPosition
) + ".*";
         List<Node> directives = getNodes( NodeType.JSP_DIRECTIVE );

Modified: incubator/jspwiki/trunk/src/webdocs/Captcha.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Captcha.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Captcha.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Captcha.jsp Sat Dec  6 10:22:53 2008
@@ -87,15 +87,15 @@
 <div style="margin: 8px">
    <p><fmt:message key="captcha.description" /></p>
 
-   <form action="<wiki:Link jsp='Captcha.jsp' format='url'/>" method="post" id="mainForm"
style="display: none;">
+   <form action="<wiki:Link jsp='Captcha.jsp' format='url' />" method="post" id="mainForm"
style="display: none;">
       <input type="hidden" value="foo" name="text" />
-      <input type="hidden" value='<%=request.getParameter("page")%>' name='page'/>
+      <input type="hidden" value='<%=request.getParameter("page")%>' name='page'
/>
       <script type="text/javascript" src="http://challenge.asirra.com/js/AsirraClientSide.js"></script>
       <script type="text/javascript">
          asirraState.SetEnlargedPosition("right");
          // asirraState.SetCellsPerRow(6);
       </script>
-      <br />
+      <br/>
       <input type="button" value="<fmt:message key="captcha.submit" />" onclick="javascript:Asirra_CheckIfHuman(HumanCheckComplete)"
/>
   </form>
 </div>

Modified: incubator/jspwiki/trunk/src/webdocs/Comment.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Comment.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Comment.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Comment.jsp Sat Dec  6 10:22:53 2008
@@ -17,6 +17,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.CommentActionBean" event="comment"
/>
 <%!
     Logger log = LoggerFactory.getLogger("JSPWiki");

Modified: incubator/jspwiki/trunk/src/webdocs/Edit.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Edit.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Edit.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Edit.jsp Sat Dec  6 10:22:53 2008
@@ -9,6 +9,7 @@
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.EditActionBean" event="edit"
/>
 
 <%!

Modified: incubator/jspwiki/trunk/src/webdocs/Error.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Error.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Error.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Error.jsp Sat Dec  6 10:22:53 2008
@@ -5,6 +5,7 @@
 <%@ page import="com.ecyrd.jspwiki.action.*" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.FileUtil" %>
 <%! 
     Logger log = LoggerFactory.getLogger("JSPWiki"); 
 %>

Modified: incubator/jspwiki/trunk/src/webdocs/Message.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Message.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Message.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Message.jsp Sat Dec  6 10:22:53 2008
@@ -3,6 +3,7 @@
 <%@ page import="com.ecyrd.jspwiki.log.LoggerFactory" %>
 <%@ page import="com.ecyrd.jspwiki.*" %>
 <%@ page import="com.ecyrd.jspwiki.action.*" %>
+<%@ page import="com.ecyrd.jspwiki.ui.stripes.*" %>
 <%@ page import="com.ecyrd.jspwiki.tags.WikiTagBase" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>

Modified: incubator/jspwiki/trunk/src/webdocs/PageModified.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/PageModified.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/PageModified.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/PageModified.jsp Sat Dec  6 10:22:53 2008
@@ -6,6 +6,7 @@
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.PageModifiedActionBean" event="conflict"
/>
 
 <%! 

Modified: incubator/jspwiki/trunk/src/webdocs/Rename.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Rename.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Rename.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Rename.jsp Sat Dec  6 10:22:53 2008
@@ -8,6 +8,7 @@
 <%@ page import="java.util.*" %>
 <%@ page import="java.text.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.RenameActionBean" event="rename"
/>
 <%!
     Logger log = LoggerFactory.getLogger("JSPWiki");

Modified: incubator/jspwiki/trunk/src/webdocs/Search.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/Search.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/Search.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/Search.jsp Sat Dec  6 10:22:53 2008
@@ -5,8 +5,10 @@
 <%@ page import="com.ecyrd.jspwiki.auth.permissions.*" %>
 <%@ page import="java.util.*" %>
 <%@ page errorPage="/Error.jsp" %>
+<%@ page import="com.ecyrd.jspwiki.search.*" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.SearchActionBean" event="find"
/>
 
 <%! 

Modified: incubator/jspwiki/trunk/src/webdocs/admin/Admin.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/admin/Admin.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/admin/Admin.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/admin/Admin.jsp Sat Dec  6 10:22:53 2008
@@ -6,6 +6,7 @@
 <%@ page import="org.apache.commons.lang.time.StopWatch" %>
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%! 
     Logger log = LoggerFactory.getLogger("JSPWiki"); 
 %>

Modified: incubator/jspwiki/trunk/src/webdocs/admin/SecurityConfig.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/admin/SecurityConfig.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/admin/SecurityConfig.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/admin/SecurityConfig.jsp Sat Dec  6 10:22:53 2008
@@ -6,6 +6,7 @@
 <%@ page import="com.ecyrd.jspwiki.auth.*" %>
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.NoneActionBean" event="none"
/>
 <%! 
   public void jspInit()

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXPreview.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXPreview.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXPreview.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXPreview.jsp Sat Dec  6 10:22:53
2008
@@ -1,5 +1,5 @@
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
-<%@ page language="java" pageEncoding="UTF-8"%>
+<%@ page language="java" pageEncoding="UTF-8" %>
 <%@ page import="com.ecyrd.jspwiki.log.Logger" %>
 <%@ page import="com.ecyrd.jspwiki.log.LoggerFactory" %>
 <%@ page import="com.ecyrd.jspwiki.*" %>
@@ -7,6 +7,8 @@
 <%@ page import="com.ecyrd.jspwiki.auth.permissions.*" %>
 <%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
+<%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.ViewActionBean" event="view"
/>
 <%! 
   public void jspInit()
   {

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXSearch.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXSearch.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXSearch.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/AJAXSearch.jsp Sat Dec  6 10:22:53
2008
@@ -14,6 +14,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.search.SearchResult" %>
 <stripes:useActionBean beanclass="com.ecyrd.jspwiki.action.SearchActionBean" event="find"
/>
 <%! 
   public void jspInit()

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/AttachmentTab.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/AttachmentTab.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/AttachmentTab.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/AttachmentTab.jsp Sat Dec  6 10:22:53
2008
@@ -7,6 +7,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%
   int MAXATTACHNAMELENGTH = 30;
   WikiContext c = WikiContextFactory.findContext( pageContext );

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/EditGroupContent.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/EditGroupContent.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/EditGroupContent.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/EditGroupContent.jsp Sat Dec  6
10:22:53 2008
@@ -11,6 +11,7 @@
 <%@ page errorPage="/Error.jsp" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%!
     Logger log = LoggerFactory.getLogger("JSPWiki");
 %>

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/GroupContent.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/GroupContent.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/GroupContent.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/GroupContent.jsp Sat Dec  6 10:22:53
2008
@@ -13,6 +13,7 @@
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%!
   Logger log = LoggerFactory.getLogger("JSPWiki");
 %>

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/InfoContent.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/InfoContent.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/InfoContent.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/InfoContent.jsp Sat Dec  6 10:22:53
2008
@@ -10,6 +10,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%
   WikiContext c = WikiContextFactory.findContext( pageContext );
   WikiPage wikiPage = c.getPage();

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/NewGroupContent.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/NewGroupContent.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/NewGroupContent.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/NewGroupContent.jsp Sat Dec  6 10:22:53
2008
@@ -10,6 +10,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%
   // Extract the group name and members
   String name = request.getParameter( "group" );

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/PageTab.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/PageTab.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/PageTab.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/PageTab.jsp Sat Dec  6 10:22:53
2008
@@ -3,7 +3,9 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
-<%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %><%--CHECK why is
this needed --%>
+<%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
+<%--CHECK why is this needed --%>
 <%
 	WikiContext c = WikiContextFactory.findContext( pageContext );
    	WikiPage p = c.getPage();

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/editors/FCK.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/editors/FCK.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/editors/FCK.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/editors/FCK.jsp Sat Dec  6 10:22:53
2008
@@ -7,6 +7,7 @@
 <%@ page import="com.ecyrd.jspwiki.render.*" %>
 <%@ page import="com.ecyrd.jspwiki.parser.JSPWikiMarkupParser" %>
 <%@ page import="com.ecyrd.jspwiki.ui.*" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%@ page import="com.ecyrd.jspwiki.filters.*" %>
 <%@ page import="org.apache.commons.lang.*" %>
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/editors/plain.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/editors/plain.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/editors/plain.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/editors/plain.jsp Sat Dec  6 10:22:53
2008
@@ -12,6 +12,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%--
         This is a plain editor for JSPWiki.
 --%>

Modified: incubator/jspwiki/trunk/src/webdocs/templates/default/editors/preview.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/trunk/src/webdocs/templates/default/editors/preview.jsp?rev=724022&r1=724021&r2=724022&view=diff
==============================================================================
--- incubator/jspwiki/trunk/src/webdocs/templates/default/editors/preview.jsp (original)
+++ incubator/jspwiki/trunk/src/webdocs/templates/default/editors/preview.jsp Sat Dec  6 10:22:53
2008
@@ -7,6 +7,7 @@
 <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
 <%@ taglib uri="/WEB-INF/stripes.tld" prefix="stripes" %>
 <%@ page import="com.ecyrd.jspwiki.action.WikiContextFactory" %>
+<%@ page import="com.ecyrd.jspwiki.util.TextUtil" %>
 <%--
         This is a special editor component for JSPWiki preview storage.
 --%>



Mime
View raw message