jspwiki-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ajaqu...@apache.org
Subject svn commit: r712929 [2/4] - in /incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH: ./ .settings/ doc/ etc/ etc/i18n/ etc/i18n/plugin/ etc/i18n/templates/ etc/ini/ lib/ src/com/ecyrd/jspwiki/ src/com/ecyrd/jspwiki/attachment/ src/com/ecyrd/jspwiki/a...
Date Tue, 11 Nov 2008 03:49:12 GMT
Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/Image.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/Image.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/Image.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/Image.java Mon Nov 10 19:49:06 2008
@@ -21,6 +21,9 @@
 package com.ecyrd.jspwiki.plugin;
 
 import java.util.*;
+
+import org.apache.jspwiki.api.ModuleData;
+
 import com.ecyrd.jspwiki.*;
 import com.ecyrd.jspwiki.attachment.AttachmentManager;
 import com.ecyrd.jspwiki.attachment.Attachment;
@@ -50,6 +53,9 @@
 // FIXME: It is not yet possible to do wiki internal links.  In order to
 //        do this cleanly, a TranslatorReader revamp is needed.
 
+@ModuleData(
+    author = "JSPWiki development group"
+)
 public class Image
     implements WikiPlugin
 {

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/InsertPage.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/InsertPage.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/InsertPage.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/InsertPage.java Mon Nov 10 19:49:06 2008
@@ -23,6 +23,7 @@
 import com.ecyrd.jspwiki.*;
 import com.ecyrd.jspwiki.auth.*;
 import com.ecyrd.jspwiki.auth.permissions.PermissionFactory;
+import com.ecyrd.jspwiki.providers.ProviderException;
 
 import java.util.*;
 
@@ -73,17 +74,16 @@
         throws PluginException
     {
         WikiEngine engine = context.getEngine();
+        ResourceBundle rb = context.getBundle(WikiPlugin.CORE_PLUGINS_RESOURCEBUNDLE);
 
         StringBuffer res = new StringBuffer();
 
         String clazz        = (String) params.get( PARAM_CLASS );
         String includedPage = (String) params.get( PARAM_PAGENAME );
         String style        = (String) params.get( PARAM_STYLE );
-        String defaultstr   = (String) params.get( PARAM_DEFAULT );
-        int    section      = TextUtil.parseIntParameter((String) params.get( PARAM_SECTION ), 
-                                                         -1 );
-        int    maxlen       = TextUtil.parseIntParameter((String) params.get( PARAM_MAXLENGTH ),
-                                                         -1 );
+        String defaultstr = (String) params.get( PARAM_DEFAULT );
+        int section = TextUtil.parseIntParameter( (String) params.get( PARAM_SECTION ), -1 );
+        int maxlen = TextUtil.parseIntParameter( (String) params.get( PARAM_MAXLENGTH ), -1 );
 
         if( style == null ) style = DEFAULT_STYLE;
 
@@ -91,8 +91,24 @@
 
         if( includedPage != null )
         {
-            WikiPage page = engine.getPage( includedPage );
-
+            WikiPage page = null;
+            try
+            {
+                String pageName = engine.getFinalPageName( includedPage );
+                if( pageName != null )
+                {
+                    page = engine.getPage( pageName );
+                }
+                else
+                {
+                    page = engine.getPage( includedPage );
+                }
+            }
+            catch( ProviderException e )
+            {
+                res.append("<span class=\"error\">" + rb.getString( "plugin.insert.notfound" ) + "</span>");
+                return res.toString();
+            }
             
             if( page != null )
             {
@@ -106,7 +122,7 @@
                 {
                     if( previousIncludes.contains( page.getName() ) )
                     {
-                        return "<span class=\"error\">Error: Circular reference - you can't include a page in itself!</span>";
+                        return "<span class=\"error\">"+ rb.getString( "plugin.insert.recursion")+"</span>";
                     }
                 }
                 else
@@ -125,7 +141,7 @@
                 if( !mgr.checkPermission( context.getWikiSession(),
                                           PermissionFactory.getPagePermission( page, "view") ) )
                 {
-                    res.append("<span class=\"error\">You do not have permission to view this included page.</span>");
+                    res.append("<span class=\"error\">"+rb.getString("plugin.insert.nopermission")+"</span>");
                     return res.toString();
                 }
 
@@ -177,15 +193,15 @@
                 }
                 else
                 {
-                    res.append("There is no page called '"+includedPage+"'.  Would you like to ");
-                    res.append("<a href=\""+context.getURL( WikiContext.EDIT, includedPage )+"\">create it?</a>");
+                    res.append(rb.getString("plugin.insert.nopage1") +" '"+includedPage+"'.  " + rb.getString( "plugin.insert.nopage2" ));
+                    res.append("<a href=\""+context.getURL( WikiContext.EDIT, includedPage )+"\"> "+rb.getString("plugin.insert.nopage3")+"</a>");
                 }
             }
         }
         else
         {
             res.append("<span class=\"error\">");
-            res.append("You have to define a page!");
+            res.append(rb.getString("plugin.insert.definepage"));
             res.append("</span>");
         }
 

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/ListLocksPlugin.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/ListLocksPlugin.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/ListLocksPlugin.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/ListLocksPlugin.java Mon Nov 10 19:49:06 2008
@@ -44,15 +44,19 @@
 
         PageManager mgr = context.getEngine().getPageManager();
         List locks = mgr.getActiveLocks();
+        ResourceBundle rb = context.getBundle(WikiPlugin.CORE_PLUGINS_RESOURCEBUNDLE);
 
         result.append("<table class=\"wikitable\">\n");
         result.append("<tr>\n");
-        result.append("<th>Page</th><th>Locked by</th><th>Acquired</th><th>Expires</th>\n");
+        result.append( "<th>" + rb.getString( "plugin.listlocks.page" ) + "</th><th>" + rb.getString( "plugin.listlocks.locked.by" )
+                       + "</th><th>" + rb.getString( "plugin.listlocks.acquired" ) + "</th><th>"
+                       + rb.getString( "plugin.listlocks.expires" ) + "</th>\n" );
         result.append("</tr>");
 
         if( locks.size() == 0 )
         {
-            result.append("<tr><td colspan=\"4\" class=\"odd\">No locks exist currently.</td></tr>\n");
+            result.append( "<tr><td colspan=\"4\" class=\"odd\">" + rb.getString( "plugin.listlocks.no.locks.exist" )
+                           + "</td></tr>\n" );
         }
         else
         {

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/PluginManager.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/PluginManager.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/PluginManager.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/plugin/PluginManager.java Mon Nov 10 19:49:06 2008
@@ -21,19 +21,17 @@
 package com.ecyrd.jspwiki.plugin;
 
 import java.io.*;
-import java.net.URL;
 import java.text.MessageFormat;
 import java.util.*;
 
+import net.sourceforge.stripes.util.ResolverUtil;
+
 import org.apache.commons.lang.ClassUtils;
 import org.apache.ecs.xhtml.*;
+import org.apache.jspwiki.api.ModuleData;
 import org.apache.log4j.Logger;
 import org.apache.oro.text.regex.*;
-import org.jdom.Document;
 import org.jdom.Element;
-import org.jdom.JDOMException;
-import org.jdom.input.SAXBuilder;
-import org.jdom.xpath.XPath;
 
 import com.ecyrd.jspwiki.*;
 import com.ecyrd.jspwiki.modules.ModuleManager;
@@ -94,23 +92,29 @@
  *  <pre>
  *  [{Counter name='foo'}]
  *  </pre>
- *  <h3>Plugin property files</h3>
+ *  <h3>Plugin annotations</h3>
+ *  <p>
+ *  As of JSPWiki 3.0, plugins may be annotated using the ModuleData
+ *  annotation.  Please see the javadoc for ModuleData.
+ *  
+ *  <h3>Adding plugins to the automatic search path</h3>
+ *  <p>
+ *  You may add a plugin by defining a deployment file "ini/jspwiki_module.xml"
+ *  with a single modules-element:
+ *  <pre>
+ *  &lt;modules package="com.mycompany.plugins"/&gt;
+ *  </pre>
+ *  This adds the plugin path "com.mycompany.plugins" in the list of
+ *  packages which are searched for WikiPlugin instances.
  *  <p>
- *  Since 2.3.25 you can also define a generic plugin XML properties file per
- *  each JAR file.
+ *  Another possibility is to use the <tt>jspwiki.plugin.searchPath</tt> -property.
+ *  For example, the equivalent invocation to the previous example:
  *  <pre>
- *  <modules>
- *   <plugin class="com.ecyrd.jspwiki.foo.TestPlugin">
- *       <author>Janne Jalkanen</author>
- *       <script>foo.js</script>
- *       <stylesheet>foo.css</stylesheet>
- *       <alias>code</alias>
- *   </plugin>
- *   <plugin class="com.ecyrd.jspwiki.foo.TestPlugin2">
- *       <author>Janne Jalkanen</author>
- *   </plugin>
- *   </modules>
+ *  jspwiki.plugin.searchPath = com.mycompany.plugins
  *  </pre>
+ *  However, this needs you to modify the property file by hand for each installation.
+ *  It is a recommended practice to create a deployment file for your plugin JAR.
+ *  
  *  <h3>Plugin lifecycle</h3>
  *
  *  <p>Plugin can implement multiple interfaces to let JSPWiki know at which stages they should
@@ -147,11 +151,6 @@
     private static final String DEFAULT_FORMS_PACKAGE = "com.ecyrd.jspwiki.forms";
 
     /**
-     *  The property name defining which packages will be searched for properties.
-     */
-    public static final String PROP_SEARCHPATH = "jspwiki.plugin.searchPath";
-
-    /**
      *  The name of the body content.  Current value is "_body".
      */
     public static final String PARAM_BODY      = "_body";
@@ -173,7 +172,7 @@
      */
     public static final String PARAM_DEBUG     = "debug";
 
-    private ArrayList<String>  m_searchPath = new ArrayList<String>();
+    private List<String>  m_searchPath;
 
     private Pattern m_pluginPattern;
 
@@ -194,19 +193,10 @@
     public PluginManager( WikiEngine engine, Properties props )
     {
         super(engine);
-        String packageNames = props.getProperty( PROP_SEARCHPATH );
 
-        if( packageNames != null )
-        {
-            StringTokenizer tok = new StringTokenizer( packageNames, "," );
-
-            while( tok.hasMoreTokens() )
-            {
-                m_searchPath.add( tok.nextToken().trim() );
-            }
-        }
-
-        registerPlugins();
+        m_searchPath = buildPluginSearchPath( props );
+        
+        registerAllPlugins();
 
         //
         //  The default packages are always added.
@@ -278,7 +268,7 @@
      *
      *  @throws ClassNotFoundException if no such class exists.
      */
-    private Class findPluginClass( String classname )
+    private Class<? extends WikiPlugin> findPluginClass( String classname )
         throws ClassNotFoundException
     {
         return ClassUtil.findClass( m_searchPath, classname );
@@ -614,7 +604,6 @@
      *  @return A DOM element
      *  @throws PluginException If plugin invocation is faulty
      */
-   @SuppressWarnings("unchecked")
    public PluginContent parsePluginLine( WikiContext context, String commandline, int pos )
         throws PluginException
     {
@@ -681,12 +670,15 @@
             m_pluginClassMap.put(name, pluginClass);
         }
 
-        // Registrar the plugin with a short convenient name.
-        name = pluginClass.getAlias();
-        if(name != null)
+        // Register the plugin with a short convenient name.
+        String[] aliases = pluginClass.getAliases();
+        if(aliases != null)
         {
-            log.debug("Registering plugin [shortName]: " + name);
-            m_pluginClassMap.put(name, pluginClass);
+            for( String a : aliases )
+            {
+                log.debug("Registering plugin [shortName]: " + a);
+                m_pluginClassMap.put(a, pluginClass);
+            }
         }
 
         // Registrar the plugin with the className with the package-part
@@ -700,61 +692,31 @@
         pluginClass.initializePlugin( m_engine );
     }
 
-    private void registerPlugins()
+    private void registerAllPlugins()
     {
         log.info( "Registering plugins" );
 
-        SAXBuilder builder = new SAXBuilder();
-
-        try
+        //
+        //  We locate every single class which implements the "WikiPlugin" interface.
+        //
+        
+        ResolverUtil<WikiPlugin> resolver = new ResolverUtil<WikiPlugin>();
+        
+        String[] paths = m_searchPath.toArray( new String[0] );
+        resolver.findImplementations( WikiPlugin.class, paths );
+        
+        Set<Class<? extends WikiPlugin>> resultSet = resolver.getClasses();
+        
+        log.debug( "Found "+resultSet.size()+" plugins" );
+        
+        for( Class<? extends WikiPlugin> clazz : resultSet )
         {
-            //
-            // Register all plugins which have created a resource containing its properties.
-            //
-            // Get all resources of all plugins.
-            //
-
-            Enumeration resources = getClass().getClassLoader().getResources( PLUGIN_RESOURCE_LOCATION );
+            WikiPluginInfo pluginInfo = WikiPluginInfo.newInstance( clazz );
 
-            while( resources.hasMoreElements() )
+            if( pluginInfo != null )
             {
-                URL resource = (URL) resources.nextElement();
-
-                try
-                {
-                    log.debug( "Processing XML: " + resource );
-
-                    Document doc = builder.build( resource );
-
-                    List plugins = XPath.selectNodes( doc, "/modules/plugin");
-
-                    for( Iterator i = plugins.iterator(); i.hasNext(); )
-                    {
-                        Element pluginEl = (Element) i.next();
-
-                        String className = pluginEl.getAttributeValue("class");
-
-                        WikiPluginInfo pluginInfo = WikiPluginInfo.newInstance( className, pluginEl );
-
-                        if( pluginInfo != null )
-                        {
-                            registerPlugin( pluginInfo );
-                        }
-                    }
-                }
-                catch( java.io.IOException e )
-                {
-                    log.error( "Couldn't load " + PLUGIN_RESOURCE_LOCATION + " resources: " + resource, e );
-                }
-                catch( JDOMException e )
-                {
-                    log.error( "Error parsing XML for plugin: "+PLUGIN_RESOURCE_LOCATION );
-                }
-            }
-        }
-        catch( java.io.IOException e )
-        {
-            log.error( "Couldn't load all " + PLUGIN_RESOURCE_LOCATION + " resources", e );
+                registerPlugin( pluginInfo );
+            } 
         }
     }
 
@@ -762,116 +724,62 @@
      *  Contains information about a bunch of plugins.
      *
      *  @author Kees Kuip
-     *  @author Janne Jalkanen
-     *
-     *  @since
      */
-    // FIXME: This class needs a better interface to return all sorts of possible
-    //        information from the plugin XML.  In fact, it probably should have
-    //        some sort of a superclass system.
     public static final class WikiPluginInfo
         extends WikiModuleInfo
     {
-        private String m_className;
-        private String m_alias;
-        private Class  m_clazz;
-
-        private boolean m_initialized = false;
-
-        /**
-         *  Creates a new plugin info object which can be used to access a plugin.
-         *
-         *  @param className Either a fully qualified class name, or a "short" name which is then
-         *                   checked against the internal list of plugin packages.
-         *  @param el A JDOM Element containing the information about this class.
-         *  @return A WikiPluginInfo object.
-         */
-        protected static WikiPluginInfo newInstance( String className, Element el )
-        {
-            if( className == null || className.length() == 0 ) return null;
-            WikiPluginInfo info = new WikiPluginInfo( className );
-
-            info.initializeFromXML( el );
-            return info;
-        }
-        /**
-         *  Initializes a plugin, if it has not yet been initialized.
-         *
-         *  @param engine The WikiEngine
-         */
-        protected void initializePlugin( WikiEngine engine )
-        {
-            if( !m_initialized )
-            {
-                // This makes sure we only try once per class, even if init fails.
-                m_initialized = true;
-
-                try
-                {
-                    WikiPlugin p = newPluginInstance();
-                    if( p instanceof InitializablePlugin )
-                    {
-                        ((InitializablePlugin)p).initialize( engine );
-                    }
-                }
-                catch( Exception e )
-                {
-                    log.info( "Cannot initialize plugin "+m_className, e );
-                }
-            }
-        }
-
-        /**
-         *  {@inheritDoc}
-         */
-        @Override
-        protected void initializeFromXML( Element el )
-        {
-            super.initializeFromXML( el );
-            m_alias = el.getChildText("alias");
-        }
-
+        String[] m_aliases;
+        Class<? extends WikiPlugin> m_clazz;
+        boolean m_initialized = false;
+        
         /**
          *  Create a new WikiPluginInfo based on the Class information.
          *  
          *  @param clazz The class to check
          *  @return A WikiPluginInfo instance
          */
-        protected static WikiPluginInfo newInstance( Class clazz )
+        protected static WikiPluginInfo newInstance( Class<? extends WikiPlugin> clazz )
         {
-            WikiPluginInfo info = new WikiPluginInfo( clazz.getName() );
+            WikiPluginInfo info = new WikiPluginInfo( clazz );
 
             return info;
         }
 
-        private WikiPluginInfo( String className )
+        private WikiPluginInfo( Class<? extends WikiPlugin> clazz )
         {
-            super(className);
-            setClassName( className );
+            super(clazz.getName());
+            setClassName( clazz.getName() );
+            initializeFromClass( clazz );
+            m_clazz = clazz;
+            
+            ModuleData md = clazz.getAnnotation( ModuleData.class );
+            if( md != null )
+            {
+                m_aliases = md.aliases();
+            }
         }
 
         private void setClassName( String fullClassName )
         {
             m_name = ClassUtils.getShortClassName( fullClassName );
-            m_className = fullClassName;
         }
-
+        
         /**
          *  Returns the full class name of this object.
          *  @return The full class name of the object.
          */
         public String getClassName()
         {
-            return m_className;
+            return m_clazz.getCanonicalName();
         }
 
         /**
          *  Returns the alias name for this object.
          *  @return An alias name for the plugin.
          */
-        public String getAlias()
+        public String[] getAliases()
         {
-            return m_alias;
+            return m_aliases;
         }
 
         /**
@@ -887,12 +795,7 @@
                    InstantiationException,
                    IllegalAccessException
         {
-            if( m_clazz == null )
-            {
-                m_clazz = Class.forName(m_className);
-            }
-
-            return (WikiPlugin) m_clazz.newInstance();
+            return m_clazz.newInstance();
         }
 
         /**
@@ -938,7 +841,7 @@
 
             try
             {
-                m_scriptText = getTextResource(m_scriptLocation);
+                m_scriptText = getTextResource(m_scriptLocation[0]);
             }
             catch( IOException ex )
             {
@@ -965,7 +868,7 @@
 
             try
             {
-                m_stylesheetText = getTextResource(m_stylesheetLocation);
+                m_stylesheetText = getTextResource(m_stylesheetLocation[0]);
             }
             catch( IOException ex )
             {
@@ -978,6 +881,33 @@
         }
 
         /**
+         *  Initializes a plugin, if it has not yet been initialized.
+         *
+         *  @param engine The WikiEngine
+         */
+        protected void initializePlugin( WikiEngine engine )
+        {
+            if( !m_initialized )
+            {
+                // This makes sure we only try once per class, even if init fails.
+                m_initialized = true;
+
+                try
+                {
+                    WikiPlugin p = newPluginInstance();
+                    if( p instanceof InitializablePlugin )
+                    {
+                        ((InitializablePlugin)p).initialize( engine );
+                    }
+                }
+                catch( Exception e )
+                {
+                    log.info( "Cannot initialize plugin "+m_clazz.getCanonicalName(), e );
+                }
+            }
+        }
+
+        /**
          *  Returns a string suitable for debugging.  Don't assume that the format
          *  would stay the same.
          *  
@@ -985,20 +915,20 @@
          */
         public String toString()
         {
-            return "Plugin :[name=" + m_name + "][className=" + m_className + "]";
+            return "Plugin :[name=" + m_name + "][className=" + m_clazz.getCanonicalName() + "]";
         }
     } // WikiPluginClass
 
     /**
      *  {@inheritDoc}
      */
-    public Collection modules()
+    public Collection<WikiPluginInfo> modules()
     {
-        TreeSet<WikiModuleInfo> ls = new TreeSet<WikiModuleInfo>();
+        TreeSet<WikiPluginInfo> ls = new TreeSet<WikiPluginInfo>();
         
         for( Iterator i = m_pluginClassMap.values().iterator(); i.hasNext(); )
         {
-            WikiModuleInfo wmi = (WikiModuleInfo)i.next();
+            WikiPluginInfo wmi = (WikiPluginInfo) i.next();
             
             if( !ls.contains(wmi) ) ls.add(wmi);
         }

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/preferences/Preferences.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/preferences/Preferences.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/preferences/Preferences.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/preferences/Preferences.java Mon Nov 10 19:49:06 2008
@@ -21,7 +21,6 @@
 package com.ecyrd.jspwiki.preferences;
 
 import java.text.DateFormat;
-import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.*;
 
@@ -31,6 +30,7 @@
 
 import org.apache.commons.lang.StringUtils;
 import org.apache.log4j.Logger;
+import org.json.JSONException;
 import org.json.JSONObject;
 
 import com.ecyrd.jspwiki.InternalWikiException;
@@ -151,7 +151,7 @@
                     prefs.put(key, jo.getString(key) );
                 }
             }
-            catch( ParseException e )
+            catch( JSONException e )
             {
             }
         }

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/providers/CachingProvider.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/providers/CachingProvider.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/providers/CachingProvider.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/providers/CachingProvider.java Mon Nov 10 19:49:06 2008
@@ -853,14 +853,21 @@
         synchronized(this)
         {
             // Clear any cached version of the old page
-            log.debug("Removing page "+from+" from cache");
-            m_cache.removeEntry( from );
-
+            log.debug("Removing from page "+from+" from cache");
+//            m_cache.removeEntry( from );
+            m_cache.putInCache( from, null );
+            m_textCache.putInCache( from, null );
+            m_historyCache.putInCache( from, null );
+            m_negCache.putInCache( from, from );
             // Clear the cache for the to page, if that page already exists
             //if ( m_cache.get( to ) != null )
             //{
-                log.debug("Removing page "+to+" from cache");
-                m_cache.removeEntry( to );
+                log.debug("Removing to page "+to+" from cache");
+//                m_cache.removeEntry( to );
+                m_cache.putInCache( to, null );
+                m_textCache.putInCache( to, null );
+                m_historyCache.putInCache( to, null );
+                m_negCache.putInCache( to, to );
             //}
         }
     }

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/rpc/json/JSONRPCManager.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/rpc/json/JSONRPCManager.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/rpc/json/JSONRPCManager.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/rpc/json/JSONRPCManager.java Mon Nov 10 19:49:06 2008
@@ -20,6 +20,7 @@
  */
 package com.ecyrd.jspwiki.rpc.json;
 
+import java.lang.reflect.AccessibleObject;
 import java.lang.reflect.Method;
 import java.security.Permission;
 import java.util.HashMap;
@@ -38,8 +39,8 @@
 import com.ecyrd.jspwiki.rpc.RPCCallable;
 import com.ecyrd.jspwiki.rpc.RPCManager;
 import com.ecyrd.jspwiki.ui.TemplateManager;
-import com.metaparadigm.jsonrpc.InvocationCallback;
-import com.metaparadigm.jsonrpc.JSONRPCBridge;
+import org.jabsorb.callback.InvocationCallback;
+import org.jabsorb.JSONRPCBridge;
 
 /**
  *  Provides an easy-to-use interface for different modules to AJAX-enable
@@ -120,7 +121,7 @@
         }
         
         if( bridge == null) bridge = JSONRPCBridge.getGlobalBridge();
-        bridge.setDebug(false);
+//        bridge. setDebug(false);
         
         return bridge;
     }
@@ -182,8 +183,6 @@
         
         /**
          *  Does not do anything.
-         * 
-         *  {@inheritDoc}
          */
         public void postInvoke(Object context, Object instance, Method method, Object result) throws Exception
         {
@@ -191,8 +190,6 @@
 
         /**
          *  Checks access against the permission given.
-         *  
-         *  {@inheritDoc}
          */
         public void preInvoke(Object context, Object instance, Method method, Object[] arguments) throws Exception
         {
@@ -225,6 +222,14 @@
             log.debug("Failed JSON permission check: "+instance);
             throw new WikiSecurityException("No permission to access this AJAX method!");
         }
+
+        public void postInvoke( Object arg0, Object arg1, AccessibleObject arg2, Object arg3 ) throws Exception
+        {
+        }
+
+        public void preInvoke( Object arg0, Object arg1, AccessibleObject arg2, Object[] arg3 ) throws Exception
+        {
+        }
         
     }
 

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/search/LuceneSearchProvider.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/search/LuceneSearchProvider.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/search/LuceneSearchProvider.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/search/LuceneSearchProvider.java Mon Nov 10 19:49:06 2008
@@ -212,18 +212,34 @@
                     for( Iterator iterator = allPages.iterator(); iterator.hasNext(); )
                     {
                         WikiPage page = (WikiPage) iterator.next();
-                        String text = m_engine.getPageManager().getPageText( page.getName(),
-                                                                             WikiProvider.LATEST_VERSION );
-                        luceneIndexPage( page, text, writer );
+                        
+                        try
+                        {
+                            String text = m_engine.getPageManager().getPageText( page.getName(),
+                                                                                 WikiProvider.LATEST_VERSION );
+                            luceneIndexPage( page, text, writer );
+                        }
+                        catch( Exception e )
+                        {
+                            log.info("Unable to index page, continuing to next: "+page.getName(),e );
+                        }
                     }
 
                     Collection allAttachments = m_engine.getAttachmentManager().getAllAttachments();
                     for( Iterator iterator = allAttachments.iterator(); iterator.hasNext(); )
                     {
                         Attachment att = (Attachment) iterator.next();
-                        String text = getAttachmentContent( att.getName(),
-                                                            WikiProvider.LATEST_VERSION );
-                        luceneIndexPage( att, text, writer );
+                        
+                        try
+                        {
+                            String text = getAttachmentContent( att.getName(),
+                                                                WikiProvider.LATEST_VERSION );
+                            luceneIndexPage( att, text, writer );
+                        }
+                        catch( Exception e )
+                        {
+                            log.info("Unable to index attachment, continuing to next: "+att.getName(),e );                            
+                        }
                     }
 
                     writer.optimize();

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/EditorManager.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/EditorManager.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/EditorManager.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/EditorManager.java Mon Nov 10 19:49:06 2008
@@ -37,7 +37,6 @@
 import com.ecyrd.jspwiki.WikiEngine;
 import com.ecyrd.jspwiki.modules.ModuleManager;
 import com.ecyrd.jspwiki.modules.WikiModuleInfo;
-import com.ecyrd.jspwiki.plugin.PluginManager;
 import com.ecyrd.jspwiki.preferences.Preferences;
 
 /**
@@ -123,7 +122,7 @@
             // Get all resources of all modules
             //
 
-            Enumeration resources = getClass().getClassLoader().getResources( PLUGIN_RESOURCE_LOCATION );
+            Enumeration resources = getClass().getClassLoader().getResources( MODULE_RESOURCE_LOCATION );
 
             while( resources.hasMoreElements() )
             {
@@ -159,17 +158,17 @@
                 }
                 catch( java.io.IOException e )
                 {
-                    log.error( "Couldn't load " + PluginManager.PLUGIN_RESOURCE_LOCATION + " resources: " + resource, e );
+                    log.error( "Couldn't load " + ModuleManager.MODULE_RESOURCE_LOCATION + " resources: " + resource, e );
                 }
                 catch( JDOMException e )
                 {
-                    log.error( "Error parsing XML for plugin: "+PluginManager.PLUGIN_RESOURCE_LOCATION );
+                    log.error( "Error parsing XML for plugin: "+ModuleManager.MODULE_RESOURCE_LOCATION );
                 }
             }
         }
         catch( java.io.IOException e )
         {
-            log.error( "Couldn't load all " + PLUGIN_RESOURCE_LOCATION + " resources", e );
+            log.error( "Couldn't load all " + MODULE_RESOURCE_LOCATION + " resources", e );
         }
     }
 

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/WikiJSPFilter.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/WikiJSPFilter.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/WikiJSPFilter.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/WikiJSPFilter.java Mon Nov 10 19:49:06 2008
@@ -20,9 +20,7 @@
  */
 package com.ecyrd.jspwiki.ui;
 
-import java.io.CharArrayWriter;
-import java.io.IOException;
-import java.io.PrintWriter;
+import java.io.*;
 
 import javax.servlet.*;
 import javax.servlet.http.HttpServletRequest;
@@ -36,6 +34,7 @@
 import com.ecyrd.jspwiki.action.WikiActionBean;
 import com.ecyrd.jspwiki.action.WikiActionBeanFactory;
 import com.ecyrd.jspwiki.event.*;
+import com.ecyrd.jspwiki.util.UtilJ2eeCompat;
 import com.ecyrd.jspwiki.util.WatchDog;
 
 /**
@@ -69,7 +68,16 @@
  */
 public class WikiJSPFilter extends WikiServletFilter
 {
+    private Boolean m_useOutputStream;
+
     /** {@inheritDoc} */
+    public void init( FilterConfig config ) throws ServletException
+    {
+        super.init( config );
+        ServletContext context = config.getServletContext();
+        m_useOutputStream = UtilJ2eeCompat.useOutputStream( context.getServerInfo() );
+    }
+
     public void doFilter( ServletRequest  request,
                           ServletResponse response,
                           FilterChain     chain )
@@ -81,8 +89,19 @@
             NDC.push( m_engine.getApplicationName()+":"+((HttpServletRequest)request).getRequestURI() );
 
             w.enterState("Filtering for URL "+((HttpServletRequest)request).getRequestURI(), 90 );
-          
-            HttpServletResponseWrapper responseWrapper = new MyServletResponseWrapper( (HttpServletResponse)response );
+            HttpServletResponseWrapper responseWrapper;
+         
+            if( m_useOutputStream )
+            {
+                log.debug( "Using ByteArrayResponseWrapper" );
+                responseWrapper = new ByteArrayResponseWrapper( (HttpServletResponse)response );
+            }
+            else
+            {
+                log.debug( "Using MyServletResponseWrapper" );
+                responseWrapper = new MyServletResponseWrapper( (HttpServletResponse)response );
+                
+            }
         
             // fire PAGE_REQUESTED event
             WikiActionBean wikiContext = WikiActionBeanFactory.findActionBean( request );
@@ -289,6 +308,75 @@
         }
     }
 
+    /**
+     *  Response wrapper for application servers which do not work with CharArrayWriter
+     *  Currently only OC4J
+     */
+    private static class ByteArrayResponseWrapper
+        extends HttpServletResponseWrapper
+    {
+        private ByteArrayOutputStream m_output;
+        private HttpServletResponse m_response;
+      
+        /** 
+         *  How large the initial buffer should be.  This should be tuned to achieve
+         *  a balance in speed and memory consumption.
+         */
+        private static final int INIT_BUFFER_SIZE = 4096;
+        
+        public ByteArrayResponseWrapper( HttpServletResponse r )
+        {
+            super(r);
+            m_output = new ByteArrayOutputStream( INIT_BUFFER_SIZE );
+            m_response = r;
+        }
+        
+        /**
+         *  Returns a writer for output; this wraps the internal buffer
+         *  into a PrintWriter.
+         */
+        public PrintWriter getWriter()
+        {
+            return new PrintWriter( getOutputStream(), true );
+        }
+
+        public ServletOutputStream getOutputStream()
+        {
+            return new MyServletOutputStream( m_output );
+        }
+
+        static class MyServletOutputStream extends ServletOutputStream
+        {
+            private DataOutputStream m_stream;
+
+            public MyServletOutputStream( OutputStream aOutput )
+            {
+                super();
+                m_stream = new DataOutputStream( aOutput );
+            }
+
+            public void write( int aInt ) throws IOException
+            {
+                m_stream.write( aInt );
+            }
+        }
+        
+        /**
+         *  Returns whatever was written so far into the Writer.
+         */
+        public String toString()
+        {
+            try
+            {
+                return m_output.toString( m_response.getCharacterEncoding() );
+            }
+            catch( UnsupportedEncodingException e )
+            {
+                log.error( ByteArrayResponseWrapper.class + " Unsupported Encoding", e );
+                return null;
+            }
+        }
+    }
 
     // events processing .......................................................
 

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/admin/beans/PluginBean.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/admin/beans/PluginBean.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/admin/beans/PluginBean.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/ui/admin/beans/PluginBean.java Mon Nov 10 19:49:06 2008
@@ -76,7 +76,7 @@
 
         tr head = new tr();
         head.addElement( new th("Name") );
-        head.addElement( new th("Alias") );
+        head.addElement( new th("Aliases") );
         head.addElement( new th("Author") );
         head.addElement( new th("Notes") );
 
@@ -89,8 +89,16 @@
 
             WikiPluginInfo info = i.next();
 
+            StringBuilder aliases = new StringBuilder();
+            
+            for( String s : info.getAliases() )
+            {
+                if( aliases.length() > 0 ) aliases.append( ", " );
+                aliases.append( s );
+            }
+
             row.addElement( new td(info.getName()) );
-            row.addElement( new td(info.getAlias()) );
+            row.addElement( new td(aliases.toString()) );
             row.addElement( new td(info.getAuthor()) );
 
             String verWarning = "";

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/com/ecyrd/jspwiki/url/ShortURLConstructor.java Mon Nov 10 19:49:06 2008
@@ -126,7 +126,8 @@
         }
         else if( context.equals(WikiContext.LOGIN) )
         {
-            return doReplacement( viewurl+"?do=Login", name, absolute ); 
+            String loginUrl = absolute ? "%uLogin.jsp?redirect=%n" : "%pLogin.jsp?redirect=%n";
+            return doReplacement( loginUrl, name, absolute ); 
         }
         else if( context.equals(WikiContext.DELETE) )
         {

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/admin/SecurityConfig.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/admin/SecurityConfig.jsp?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/admin/SecurityConfig.jsp (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/admin/SecurityConfig.jsp Mon Nov 10 19:49:06 2008
@@ -125,9 +125,9 @@
 <!-- Notify users which JAAS configs we need to find -->
 <p>JSPWiki wires up its own JAAS to define the authentication process, and does not rely on the JRE configuration. By default, JSPWiki configures its JAAS login stack to use the UserDatabaseLoginModule. You can specify a custom login module by setting the <code>jspwiki.loginModule.class</code> property in <code>jspwiki.properties</code>.</p>
 
-<wiki:Messages div="information" topic="<%=SecurityVerifier.INFO+"java.security.auth.login.config"%>" prefix="Good news: "/>
-<wiki:Messages div="warning" topic="<%=SecurityVerifier.WARNING+"java.security.auth.login.config"%>" prefix="We found some potential problems with your configuration: "/>
-<wiki:Messages div="error" topic="<%=SecurityVerifier.ERROR+"java.security.auth.login.config"%>" prefix="We found some errors with your configuration: " />
+<wiki:Messages div="information" topic='<%=SecurityVerifier.INFO+"java.security.auth.login.config"%>' prefix="Good news: "/>
+<wiki:Messages div="warning" topic='<%=SecurityVerifier.WARNING+"java.security.auth.login.config"%>' prefix="We found some potential problems with your configuration: "/>
+<wiki:Messages div="error" topic='<%=SecurityVerifier.ERROR+"java.security.auth.login.config"%>' prefix="We found some errors with your configuration: " />
 
 <!-- Print JAAS configuration status -->
 <p>The JAAS login configuration is correctly configured if the <code>jspwiki.loginModule.class</code> property specifies

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/rss.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/rss.jsp?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/rss.jsp (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/rss.jsp Mon Nov 10 19:49:06 2008
@@ -5,10 +5,13 @@
 <%@ page import="java.text.*" %>
 <%@ page import="com.ecyrd.jspwiki.rss.*" %>
 <%@ page import="com.ecyrd.jspwiki.util.*" %>
+<%@ page import="com.opensymphony.oscache.base.*" %>
 <%@ taglib uri="/WEB-INF/oscache.tld" prefix="oscache" %>
 
 <%!
     Logger log = Logger.getLogger("JSPWiki");
+    Cache m_cache = new Cache( true, false, false, true, 
+                               "com.opensymphony.oscache.base.algorithm.LRUCache", 256 );
 %>
 
 <%
@@ -104,10 +107,37 @@
 
     response.addDateHeader("Last-Modified",latest.getTime());
     response.addHeader("ETag", HttpUtil.createETag(wikipage) );
-%>
-<%-- <oscache:cache time="300"> --%>
-<%
-    out.println(wiki.getRSSGenerator().generateFeed( wikiContext, changed, mode, type ));
-%>
-<%-- </oscache:cache> --%>
-<% w.exitState(); %>
+    
+    //
+    //  Try to get the RSS XML from the cache.  We build the hashkey
+    //  based on the LastModified-date, so whenever it changes, so does
+    //  the hashkey so we don't have to make any special modifications.
+    //
+    //  TODO: Figure out if it would be a good idea to use a disk-based
+    //        cache here.
+    //
+    String hashKey = wikipage.getName()+";"+mode+";"+type+";"+latest.getTime();
+    
+    String rss = "";
+    
+    try
+    {
+        rss = (String)m_cache.getFromCache(hashKey);
+    }
+    catch( NeedsRefreshException e )
+    { 
+        try
+        {
+            rss = wiki.getRSSGenerator().generateFeed( wikiContext, changed, mode, type );
+            m_cache.putInCache(hashKey,rss);
+        }
+        catch( Exception e1 )
+        {
+            m_cache.cancelUpdate(hashKey);            
+        }
+    }
+    
+    out.println(rss);
+    
+    w.exitState(); 
+    %>

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/scripts/jspwiki-edit.js
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/scripts/jspwiki-edit.js?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/scripts/jspwiki-edit.js (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/scripts/jspwiki-edit.js Mon Nov 10 19:49:06 2008
@@ -201,6 +201,9 @@
 			.addEvent('keyup', this.getSuggestions.bind(this))
 			.addEvent('change', this.onChangeTextarea.bind(this))
 			.focus();
+
+		/* regularly refresh section-edit toc and sneak-preview */		
+		this.textarea.fireEvent.periodical(3000,this.textarea,['change']);		
 	},
 
 	/* add textarea resize drag bar */
@@ -483,12 +486,15 @@
 	},
 
 	onPageLoadPreview : function(){
-		if( $$('#sneakpreview','#autopreview').length != 2) return;
-		$('autopreview')
+		var checkbox = $('autopreview');
+
+		if(!checkbox) return;
+
+		checkbox
 			.setProperty('checked', Wiki.prefs.get('autopreview') || false)
 			.addEvent('click', function(){ 
 				var ta = this.textarea,
-					isOn = $('autopreview').checked;
+					isOn = checkbox.checked;
 
 				$('sneakpreview').empty();
 				ta.removeEvents('preview');
@@ -501,22 +507,14 @@
 
 	refreshPreview: function(){
     	var	preview = $('sneakpreview');
-		this.bgcolor = this.bgcolor || preview.getStyle('background-color');
 
-    	var	bgcolorfx = (this.bgcolor == 'transparent' ) ? '#fff' : this.bgcolor,
-    		previewfx = preview.effect('background-color', {
-    			duration:2000,
-    			wait:false,
-    			onComplete:function(){ preview.setStyle('background-color', this.bgcolor); }
-    		});
-
-		//TODO: put a spinner in the preview result block
+		$('previewSpin').show();
 		new Ajax( Wiki.TemplateUrl + "/AJAXPreview.jsp?page="+Wiki.PageName, { 
 			postBody: 'wikimarkup=' + encodeURIComponent(this.textarea.value),
 			update: preview,
 			onComplete: function(){ 
+				$('previewSpin').hide();
 				Wiki.renderPage(preview, Wiki.PageName);
-				previewfx.start('#ffff88',bgcolorfx); 
 			}
 		}).request();
 	},
@@ -645,6 +643,7 @@
 	 * happens when 
 	 *  (i)  textarea is changed and deselected (click outside the textarea) 
 	 *  (ii) user clicks a toolbar-button
+	 *  (iii) periodical
 	 *  
 	 * 1) copy section textarea at the right offset of the main textarea
 	 * 2) refresh the section-edit menu
@@ -652,6 +651,9 @@
 	onChangeTextarea : function(){
 		var	ta = this.textarea,	ma = this.mainarea;
 
+		if(ta.value == this.cacheTextarea) return;
+		this.cacheTextarea=ta.value;
+
 		if( this.sections ){
 			var	s = ta.value;
 			if( s.lastIndexOf("\n") + 1 != s.length ) ta.value += '\n';

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupContent.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupContent.jsp?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupContent.jsp (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupContent.jsp Mon Nov 10 19:49:06 2008
@@ -6,6 +6,7 @@
 <%@ page import="com.ecyrd.jspwiki.auth.PrincipalComparator" %>
 <%@ page import="com.ecyrd.jspwiki.auth.authorize.Group" %>
 <%@ page import="com.ecyrd.jspwiki.auth.authorize.GroupManager" %>
+<%@ page import="com.ecyrd.jspwiki.preferences.Preferences" %>
 <%@ page import="org.apache.log4j.*" %>
 <%@ page errorPage="/Error.jsp" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
@@ -35,12 +36,12 @@
     creator = group.getCreator();
     if ( group.getCreated() != null )
     {
-      created = group.getCreated().toString();
+      created = Preferences.renderDate(WikiContext.findContext( pageContext ), group.getCreated(),Preferences.TimeFormat.DATETIME);
     }
     modifier = group.getModifier();
     if ( group.getLastModified() != null )
     {
-      modified = group.getLastModified().toString();
+      modified = Preferences.renderDate(WikiContext.findContext( pageContext ), group.getLastModified(),Preferences.TimeFormat.DATETIME) ; 
     }
   }
   name = TextUtil.replaceEntities(name);

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupTab.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupTab.jsp?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupTab.jsp (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/GroupTab.jsp Mon Nov 10 19:49:06 2008
@@ -7,6 +7,7 @@
 <%@ page import="com.ecyrd.jspwiki.auth.PrincipalComparator" %>
 <%@ page import="com.ecyrd.jspwiki.auth.authorize.Group" %>
 <%@ page import="com.ecyrd.jspwiki.auth.authorize.GroupManager" %>
+<%@ page import="com.ecyrd.jspwiki.preferences.Preferences" %>
 <%@ page import="org.apache.log4j.*" %>
 <%@ page errorPage="/Error.jsp" %>
 <%@ page import="javax.servlet.jsp.jstl.fmt.*" %>
@@ -34,11 +35,11 @@
       
       ss.append( delim );
       mf = new MessageFormat(LocaleSupport.getLocalizedMessage(pageContext, "grp.createdon") );
-      args = new Object[]{(group.getCreated()==null) ? "" : group.getCreated().toString(), group.getCreator()};
+      args = new Object[]{(group.getCreated()==null) ? "" : Preferences.renderDate(WikiContext.findContext( pageContext ), group.getCreated(),Preferences.TimeFormat.DATETIME), group.getCreator()};
       ss.append( mf.format( args ) );
       
       mf = new MessageFormat(LocaleSupport.getLocalizedMessage(pageContext, "grp.lastmodified") );
-      args = new Object[]{(group.getCreated()==null) ? "" : group.getCreated().toString(), group.getModifier()};
+      args = new Object[]{(group.getLastModified()==null) ? "" : Preferences.renderDate(WikiContext.findContext( pageContext ), group.getLastModified(),Preferences.TimeFormat.DATETIME), group.getModifier()};
       ss.append( mf.format( args ) );
       
       ss.append( "\", " );

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/editors/plain.jsp
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/editors/plain.jsp?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/editors/plain.jsp (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/editors/plain.jsp Mon Nov 10 19:49:06 2008
@@ -211,6 +211,7 @@
 <div id="sneakpreviewheader">
   <input type="checkbox" name="autopreview" id="autopreview" <%=TextUtil.isPositive((String)session.getAttribute("autopreview")) ? "checked='checked'" : ""%> />
   <label for="autopreview" title="<fmt:message key='editor.plain.sneakpreview.title'/>"><fmt:message key="editor.plain.sneakpreview"/></label>	  
+  <span id="previewSpin" class="spin" style="position:absolute;display:none;"></span>
 </div>
 <div id="sneakpreview" ></div>
 

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/jspwiki.css
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/jspwiki.css?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/jspwiki.css (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/webdocs/templates/default/jspwiki.css Mon Nov 10 19:49:06 2008
@@ -52,6 +52,7 @@
 }
 #favorites {
 	float:left;
+	overflow:hidden; /*avoid overflow for wide content of leftmenu or leftmenufooter */
 	margin-top:1.75em;
 	width:18%;
 	padding:0.5em;
@@ -178,11 +179,11 @@
 	line-height:1.2;
 }
 h2 { font-size: 150%; }
-h2 .editsection { font-size: 67%; padding-left:1em;}
+h2 .editsection, h2 .hashlink { font-size: 67%; padding-left:1em;}
 h3 { font-size: 132%; }
-h3 .editsection { font-size: 76%; padding-left:1em;}
+h3 .editsection, h3 .hashlink { font-size: 76%; padding-left:1em;}
 h4 { font-size: 116%; }
-h4 .editsection { font-size: 86%; padding-left:1em;}
+h4 .editsection, h4 .hashlink { font-size: 86%; padding-left:1em;}
 .editsection {
 	font-weight:normal;
 	line-height:1.2;
@@ -347,7 +348,17 @@
 a.infolink img {
 	display:none;
 }*/
-
+/* hashlink */
+a.hashlink {
+	color:transparent;
+	line-height:1.2;
+	padding:0.25em;
+	text-decoration:none;
+}
+a.hashlink:hover {
+	background-color:#eee;
+	color:blue;
+}
 /* +++ 260 Image styles +++ */
 img {
 	border:none;
@@ -714,6 +725,7 @@
 	width:99%;
 }
 #toctoc {
+	position:relative;
 	margin:0.5em 0;
 }
 #toctoc label {
@@ -963,6 +975,9 @@
 	background:#eee;
 	/*line-height:1;*/
 }
+.pagination a {
+	cursor:pointer;
+}
 .pagination a, .pagination .cursor {
 	padding:0.5em;
 }
@@ -1156,17 +1171,16 @@
 }
 #searchSubmit {
 	position:absolute;
-    top: 5px;
-	right: 3px;
+    top:5px;
+	right:3px;
 
 	margin:0; 
 	padding:0;
 	width:16px; 
 	height:16px;
-	border:none;
-	background: #fff url(images/search.gif) no-repeat center;
+	border:none; 
+	background: url(images/search.gif) no-repeat center;
 	overflow:hidden;	
-    text-indent:16px;
     cursor:pointer;
 }
 #searchboxMenu {
@@ -1246,9 +1260,9 @@
 
 /* +++ 625 Table of contents plugin +++ */
 div.toc {
-	 width:60%; 
-	 float:left;
-	 clear:left;
+	width:60%; 
+	float:left;
+	clear:left;
 }
 /* duplicate toc items links back to the first rendered table of contents */
 a.toc {

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/About.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/About.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/About.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/About.txt Mon Nov 10 19:49:06 2008
@@ -1,15 +1,14 @@
-Êú¨ Wiki ÈááÁî®??Ü [JSP|http://java.sun.com/products/jsp] ÊäÄÊúØÔºåËøôÊ??ÁöÑÊäÄÊúØ??øÂæó Wiki ÈùûÂ??ÂÆ?ÊòìÊõ¥Êñ?ÔºåÂ????î?ºº??éÊØî§ß§öÊï?Âü???é[ÂéüÂßãÁâàÊú¨|http://c2.com/cgi/wiki]ÁöÑ Wiki ˶ÅÊõ¥Â???ÄÇÂÆöÂà?ÁöÑ bean Ë¥üË¥£Â?ÜÊñáÊú¨Ë?¨Êç¢Êàê HTML ÂÜÖÂÆ??ÄÇ
-
-§ß§öÊï?[ÁºñËæëÊ?áËÆ?|TextFormattingRules]Ê??ÊçÆ [Sensei's Library|http://senseis.xmp.net] ËÆæËÆ°ÔºåÂÆÉÊòØ??íËÅîÁ?ë??äÊúÄÂ??ÁöÑ GO Á´ôÁÇ???ã??Ä?ÄÇÊàëËßâÂæó?ªñ?ª¨ÁöÑÊ?áËÆ?ÈùûÂ??ÂÆ?ÊòìÔºåËÄå??îÊ?ÖÊô??ÄÇ
-
-Êú¨ WikiÔºàJSPWikiÔºâÁöÑËÆ?ÂèØÂçèËÆÆÊòØ [Apache License, Version 2.0|http://www.apache.org/licenses/LICENSE-2.0]?ÄÇËØ?ÂèÇËÄÉ [http://incubator.apache.org/jspwiki] ??ÜËߣÊõ¥Â§ö?ø°ÊÅØ?ÄÇ
-
-¶ÇÊûúÊÇ®ÂØ? JSPWiki ºÄÂèëÊÑüÂÖ¥Ë?£ÔºåJSPWiki ÁöÑ??ªÈ°µÊòØ [http://www.jspwiki.org]?ÄÇ??ãÈù¢ÊòØ??Ä??õÂø´ÈÄüÈìæÊé?Ôºö
-
-* [Áº?Èô?Êä?Âëä|JSPWiki:SubmitBugReport] ÊàñËÄÖ[Áúã??Ä??ã Open Áº?Èô?ÁöÑÂàóË°®|JSPWiki:OpenBugs].
-* [Ë¥°ÁåÆÊñ?ÁöÑÊÉ?Ê?ï|JSPWiki:SubmitNewIdea]?ÄÇ
-* Áúã??Ä??ãÊúÄÊñ?ÁöÑ [JSPWiki FAQ|JSPWiki:JSPWikiFAQ]
-* ÂتÊâæÂÖ??ªñÁöÑ[Êèí?ª?|JSPWiki:ContributedPlugins]?ÄÅ[Ê®°Êùø|JSPWiki:ContributedTemplates]?ÄÅ[Ëøáʪ§Âô®|JSPWiki:ContributedFilters]?ÄÅ[Êèê?æõÁ®ãÂ?è|JSPWiki:ContributedProviders] ÊàñËÄÖ[ÂÖ??ªñÊØîËæÉÈÖ?ÁöÑ??úË?ø|JSPWiki:ContributedCode]?ÄÇ
-
-Á?ùÂÆöÂà?(hacking)ÊÑâÂø´ÔºåÊÑüË?¢ÊÇ®ÈÄâÊã©??Ü JSPWikiÔºÅ
-
+本 Wiki 采用了 [JSP|http://java.sun.com/products/jsp] 技术,这样的技术使得 Wiki 非常容易更新,并且似乎比大多数基于[原始版本|http://c2.com/cgi/wiki]的 Wiki 要更好。定制的 bean 负责将文本转换成 HTML 内容。
+
+大多数[编辑标记|TextFormattingRules]根据 [Sensei's Library|http://senseis.xmp.net] 设计,它是互联网上最好的 GO 站点之一。我觉得他们的标记非常容易,而且清晰。
+
+本 Wiki(JSPWiki)的许可协议是 [Apache License, Version 2.0|http://www.apache.org/licenses/LICENSE-2.0]。请参考 [http://incubator.apache.org/jspwiki] 了解更多信息。
+
+如果您对 JSPWiki 开发感兴趣,JSPWiki 的主页是 [http://www.jspwiki.org]。下面是一些快速链接:
+
+* [缺陷报告|JSPWiki:SubmitBugReport] 或者[看一下 Open 缺陷的列表|JSPWiki:OpenBugs].
+* [贡献新的想法|JSPWiki:SubmitNewIdea]。
+* 看一下最新的 [JSPWiki FAQ|JSPWiki:JSPWikiFAQ]
+* 寻找其他的[插件|JSPWiki:ContributedPlugins]、[模板|JSPWiki:ContributedTemplates]、[过滤器|JSPWiki:ContributedFilters]、[提供程序|JSPWiki:ContributedProviders] 或者[其他比较酷的东西|JSPWiki:ContributedCode]。
+
+祝定制(hacking)愉快,感谢您选择了 JSPWiki!

Propchange: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/ApprovalRequiredForPageChanges.txt
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Propchange: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/ApprovalRequiredForUserProfiles.txt
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/Community.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/Community.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/Community.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/Community.txt Mon Nov 10 19:49:06 2008
@@ -1,47 +1,47 @@
-[{TableOfContents}]
-
-!! ÈÇÆ?ª?ÂàóË°®
-Âú®Ëøô??? wiki ??ã§ñÊúâ???Áî®??éËÆ®ËÆ?ÁöÑ JSPWiki ÈÇÆ?ª?ÂàóË°®?ÄÇÂæàÈÄÇÂêàËÆ®ËÆ?ËØ?¶ÇË°???Å?ÄÅÈóÆÈ¢ò?ÄźÄÂèëÁ?âÁ?âÁöÑÈóÆÈ¢ò?ÄÇ
-
-ÁõÆÂâçÊúâ??§???ÈÇÆ?ª?ÂàóË°®Ôºö''jspwiki-users'' Âíå ''jspwiki-dev''?ÄÇ
-
-!JSPWiki-user
-
-jspwiki-user ÈÇÆ?ª?ÂàóË°®Áî± Apache Incubator ÊâòÁÆ°?ÄÇÂèØ?ª?ÈÄöËøáÂèëÈÄÅÈÇÆ?ª?Âà??ª???ãÂú?ÂùÄÁî?ËØ?Âä?ÂÖ?Ôºö[jspwiki-user-subscribe@incubator.apache.org|mailto:jspwiki-user-subscribe@incubator.apache.org]?ÄÇÈÇÆ?ª?ÂàóË°®Â?íÊ°£??ç??é  [http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-user/|http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-user/]
-
-[?ª?ÂâçÁöÑÂàóË°®Â?íÊ°£|http://www.ecyrd.com/pipermail/jspwiki-users/] ËøòÂú®?ÄÇÂè¶Â§ñÔºåÂú® Nabble ??äËøòÊúâ??Ä??? [ÂâØÂ?íÊ°£|http://www.nabble.com/JspWiki---User-f2680.html]?ÄÇ
-
-!JSPWiki-dev
-
-Ëøô???ÂàóË°®??ªË¶ÅÈíàÂØ? JSPWiki ºÄÂèëËÄÖ?ÄǶÇÊûúÊãÖÂøÉʪ°Â§©È£ûÁöÑÊöóËØ?ÁöÑËØùÔºåÊúÄÂ??ËøòÊòØÂà´Âä?ÂÖ??ÄÇjspwiki-dev ÂàóË°®Áî± Apache ÊâòÁÆ°ÔºåÊâÄ?ª?ÊÇ®ÂèØ?ª?ÈÄöËøáÁªô??ãÈù¢ÁöÑÂú?ÂùÄÂèë???ÈÇÆ?ª?Êù?Âä?ÂÖ?Ôºö[jspwiki-dev-subscribe@incubator.apache.org|mailto:jspwiki-dev-subscribe@incubator.apache.org]?ÄÇÈÇÆ?ª?ÂàóË°®Â?íÊ°£??ç??é [http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-dev/|http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-dev/]
-
-!JSPWiki-commits
-
-¶ÇÊûúËÆ¢ÈòÖ??ÜËøô???ÂàóË°®Ôºå????ºöÂú®Âêë SVN Â?ìÊèê??§??ÜÊñ?ÁöÑÊàñ?øÆÊî?ËøáÁöÑÊñá?ª?Êó??ºöÊî?Âà?ÈÇÆ?ª?ÈÄöÁü??ÄÇ
-jspwiki-commits ÂàóË°®Áî± Apache ÊâòÁÆ°ÔºåÊÇ®ÂèØ?ª?ÈÄöËøáÁªô??ãÈù¢ÁöÑÂú?ÂùÄÂèëÈÄÅÈÇÆ?ª?Âä?ÂÖ?Ôºö[jspwiki-dev-subscribe@incubator.apache.org|mailto:jspwiki-dev-subscribe@incubator.apache.org]?ÄÇÈÇÆ?ª?ÂàóË°®Â?íÊ°£??ç??é http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-commits/
-
-!ÂèñÊ?àËÆ¢ÈòÖ
-
-ÂèñÊ?àËÆ¢ÈòÖÂêåÊ??ÂÆ?ÊòìÔºöÊÇ®Âè?ÈúÄÁî®ËÆ¢ÈòÖÂàóË°®Êó???øÁî®ÁöÑÈÇÆ?ª?Âú?ÂùÄÁªô jspwiki-<user|dev|commits>-unsubscribe@incubator.apache.org ÂèëÈÄÅÈÇÆ?ª?Âç?ÂèØÂÆåÊàê?ÄÇ
-
-¶ÇÊûúÊÇ®ÊÉ?Êé¢Á©???Ä??õÊúâË?£ÁöÑÈóÆÈ¢òÁöÑËØùÔºå?ª?ÂâçÁöÑ JSPWiki-devÔºàÂà? 2007Â?¥10ÊúàÔºâÂ?íÊ°£[ËøòÂèØ?ª?Áî®|http://www.ecyrd.com/pipermail/jspwiki-dev/]?ÄÇ
-
-!! ÂÖ??ªñ˵ÑÊ?ê
-
-! IrcChannel - ??éºÄÂèëËÄÖÂú®Á?øËÅ䧩ԺÅ
-
-Âú® [Freenode|http://www.freenode.net] ??äÊúâ??? JSPWiki [IRC|http://www.mirc.com/irc.html] È¢ëÈÅìÔºåÂêçÁß????Ôºö#jspwiki. ¶ÇÊûúÊúâ?ªª??ïÁñëÈóÆÔºåÊàñËÄÖÂè?ÊòØÊÉ?ËÅäËÅäÔºåÂèØ?ª?ËøõÂéªÁúãÁúã?ÄÇ
-
-ÈúÄ˶ÅÊ?®ÊÑèÁöÑÊòØÔºåÊúâ??õÊó?ÊƵËøô???È¢ëÈÅìÈáåÈù¢?ºöÁõ?Â?ìÂÆâÈùôÔºå¶ÇÊûúÂèë??ÜÊ?àÊÅØÊ?°ÊúâÂõû§çÁöÑËØùÔºå±û??éÊ?£Â??Ôºå??ç˶ÅÊ?ÑÊ?î?ÄÇÂ?±Âú®Á?øÁ?â??Ä?ºöÂÑøÁúãÁúã?Ķ?Ķ
-
-È¢ëÈÅì??äÁöÑÂ??ÂÆ¢Ôºõ
-* [Janne Jalkanen|http://www.jspwiki.org/wiki/JanneJalkanen] (Ecyrd)ÔºöÊó?Âå???? GMT+2.
-
-! [FaceBook | http://www.facebook.com/group.php?gid=11138025370]
-
-Âè¶Â§ñÔºåÊàëËøòÂú® Facebook ??äª???Ü??Ä??? JSPWiki Áî®Êà?ÁªÑ??ú???®±??ê?ÄǶÇÊûúÊÇ®ÊòØ Facebook ??äÁöÑÂ??ÂÆ¢ÔºåÂèØ?ª?ÂéªÁúãÁúãÔºÅ
-
-ÔºàÂ?ìÁÑ?ÔºåÊàë?ª¨??ç?ºöÁî®Ëøô???ÊõøÊç¢?ªª??ïÁé?ÊúâÁöÑÁ´ôÁÇ??ÄÇ??çËøáÔºåÊØè??????ËøòÊúâ?ªñ?ª¨ÁöÑ???Âèã?ºº??é??üÂú® Facebook ??äÔºåÊàë?ºº??éËßâÂæóÂÜçÂä???Ä???È¢ëÈÅì??ü??çÈîôÔºâ
--- Janne 2007Â?¥9Êúà17Êó?
-
-* [JSPWiki 开发博客|http://blog.jspwiki.org/]
+[{TableOfContents}]
+
+!! 邮件列表
+在这个 wiki 之外有个用于讨论的 JSPWiki 邮件列表。很适合讨论诸如补丁、问题、开发等等的问题。
+
+目前有两个邮件列表:''jspwiki-users'' 和 ''jspwiki-dev''。
+
+!JSPWiki-user
+
+jspwiki-user 邮件列表由 Apache Incubator 托管。可以通过发送邮件到以下地址申请加入:[jspwiki-user-subscribe@incubator.apache.org|mailto:jspwiki-user-subscribe@incubator.apache.org]。邮件列表归档位于  [http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-user/|http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-user/]
+
+[以前的列表归档|http://www.ecyrd.com/pipermail/jspwiki-users/] 还在。另外,在 Nabble 上还有一个 [副归档|http://www.nabble.com/JspWiki---User-f2680.html]。
+
+!JSPWiki-dev
+
+这个列表主要针对 JSPWiki 开发者。如果担心满天飞的暗语的话,最好还是别加入。jspwiki-dev 列表由 Apache 托管,所以您可以通过给下面的地址发个邮件来加入:[jspwiki-dev-subscribe@incubator.apache.org|mailto:jspwiki-dev-subscribe@incubator.apache.org]。邮件列表归档位于 [http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-dev/|http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-dev/]
+
+!JSPWiki-commits
+
+如果订阅了这个列表,你会在向 SVN 库提交了新的或修改过的文件时会收到邮件通知。
+jspwiki-commits 列表由 Apache 托管,您可以通过给下面的地址发送邮件加入:[jspwiki-dev-subscribe@incubator.apache.org|mailto:jspwiki-dev-subscribe@incubator.apache.org]。邮件列表归档位于 http://mail-archives.apache.org/mod_mbox/incubator-jspwiki-commits/
+
+!取消订阅
+
+取消订阅同样容易:您只需用订阅列表时使用的邮件地址给 jspwiki-<user|dev|commits>-unsubscribe@incubator.apache.org 发送邮件即可完成。
+
+如果您想探究一些有趣的问题的话,以前的 JSPWiki-dev(到 2007年10月)归档[还可以用|http://www.ecyrd.com/pipermail/jspwiki-dev/]。
+
+!! 其他资源
+
+! IrcChannel - 与开发者在线聊天!
+
+在 [Freenode|http://www.freenode.net] 上有个 JSPWiki [IRC|http://www.mirc.com/irc.html] 频道,名称为:#jspwiki. 如果有任何疑问,或者只是想聊聊,可以进去看看。
+
+需要注意的是,有些时段这个频道里面会相当安静,如果发了消息没有回复的话,属于正常,不要泄气。就在线等一会儿看看……
+
+频道上的常客;
+* [Janne Jalkanen|http://www.jspwiki.org/wiki/JanneJalkanen] (Ecyrd):时区为 GMT+2.
+
+! [FaceBook | http://www.facebook.com/group.php?gid=11138025370]
+
+另外,我还在 Facebook 上建了一个 JSPWiki 用户组作为娱乐。如果您是 Facebook 上的常客,可以去看看!
+
+(当然,我们不会用这个替换任何现有的站点。不过,每个人还有他们的亲友似乎也在 Facebook 上,我似乎觉得再加一个频道也不错)
+-- Janne 2007年9月17日
+
+* [JSPWiki 开发博客|http://blog.jspwiki.org/]
\ No newline at end of file

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/CopyrightNotice.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/CopyrightNotice.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/CopyrightNotice.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/CopyrightNotice.txt Mon Nov 10 19:49:06 2008
@@ -1 +1 @@
-Êää???ÁöÑ[ÁâàÊùÉ?ø°ÊÅØ|CopyrightNotice]ÊîæÂú®ËøôÂÑøÔºÅ
+把你的[版权信息|CopyrightNotice]放在这儿!

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditFindAndReplaceHelp.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditFindAndReplaceHelp.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditFindAndReplaceHelp.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditFindAndReplaceHelp.txt Mon Nov 10 19:49:06 2008
@@ -1,26 +1,26 @@
-ÂèØ?ª?Âú®?ÄúÊü?ÊâæÂÜÖÂÆ??ÄùÂ?óÊƵ??øÁî®ÂÖÉÂ?óÁ¨¶Ôºö
-
-|.      |Èô§Êç¢Ë°å§ñÁöÑ?ªªÊÑèÂ?óÁ¨¶              |+      |??Äʨ°Êàñ§öʨ°
-|*      |Èõ?ʨ°Êàñ§öʨ°                      |?      |Èõ?ʨ°Êàñ??Äʨ°
-|{n}    |Âè?Âå?ÈÖç n ʨ°                     |{n,m}  |ÊúÄÂ?ë n ʨ°ÔºåÊúħö m ʨ°
-|~|     |ÁÆ°ÈÅìÁ¨¶Ôºö{{a~|b}} Âå?ÈÖç a Êàñ b    | -     |ËøûÂ?óÁ¨¶ÔºåÂå?ÈÖçÂ?óÁ¨¶Âå?Èó¥
-|^      |??ÄË°åÁöÑ˵?Âßã??çÁ?Æ                  |$      |Ë°åÂ?æ
-|[[...] |ÈõÜÂêà???ÁöÑ??Ä???Â?óÁ¨¶                |[[^...] |Âê¶ÂÆöÂ?óÁ¨¶ÈõÜÂêà
-|\b     |单词分界符                      |\B     |非单词分界符
-|\d     |Êï?Â?ó [[0-9]                     |\D     |ÈùûÊï?Â?ó [[^0-9]
-|\s     |Âçï???Á©?Áô?Â?óÁ¨¶                    |\S     |Âçï???ÈùûÁ©?Áô?Â?óÁ¨¶
-|\w     |[[A-Za-z0-9_]                   |\W     |[[^A-Za-z0-9_]
-|(...)  |ÂàÜÁªÑ?øùÂ?ò??? $1..$9               |\.     |ÂØ?ÂÖÉÂ?óÁ¨¶ÁöÑË?¨??â
-
-?ÄúÊõøÊç¢?ÄùËá?Âä®ÂèØ?ª???øÁî® $1..$9 ??ú???ÂØ??ÄúÊü?Êâæ?ÄùÂ?óÊƵ???Êã¨Âè????ÂÜÖÂÆ?ÁöÑÂèçÂêëºïÁî®?ÄÇ
-----
-Á§??æãÔºö\\
-
-Êü?Êâæ __/abc|def/__ ?ºöÂå?ÈÖçÂçïËØç 'abc' Êàñ 'def'\\
-Êü?Êâæ __/bwiki/b__ ?ºöÂå?ÈÖç 'wiki' ??Ü??çÂå?ÈÖç 'jspwiki'?ÄÇ\\
-Êü?Êâæ __^[[IVXMDCL]+\.__ ?ºöÂå?ÈÖç?ªªÊÑèÁªÑÂêàÁöÑÁ?óÈ©¨Êï?Â?ó?ª?ÂèäÁ¥ßË?üÂÖ?ÂêéÁöÑÂè?ÁÇ? '.'\\
-Êü?Êâæ __/(-?\d+)(\d{3})/__ Â??Áî® __$1,$2__ ÊõøÊç¢?ºöÂú®Â§ßÁöÑÊï?Â?ó???ÊèíÂÖ?ÈÄóÂè? ','?ÄÇ
-
-Ëøô???ÊòØ [EditFindAndReplaceHelp] È°µÈù¢?ÄÇ
-[Êõ¥Â§öÂÖ???éÊ?£ÂàôË°®ËææºèÁöÑ?ø°ÊÅØ|http://www.regular-expressions.info/javascript.html]
-?ª?Âèä [RegExp Ê?ôÁõí|http://www.regular-expressions.info/javascriptexample.html]\\
+可以在“查找内容”字段使用元字符:
+
+|.      |除换行外的任意字符              |+      |一次或多次
+|*      |零次或多次                      |?      |零次或一次
+|{n}    |只匹配 n 次                     |{n,m}  |最少 n 次,最多 m 次
+|~|     |管道符:{{a~|b}} 匹配 a 或 b    | -     |连字符,匹配字符区间
+|^      |一行的起始位置                  |$      |行尾
+|[[...] |集合中的一个字符                |[[^...] |否定字符集合
+|\b     |单词分界符                      |\B     |非单词分界符
+|\d     |数字 [[0-9]                     |\D     |非数字 [[^0-9]
+|\s     |单个空白字符                    |\S     |单个非空白字符
+|\w     |[[A-Za-z0-9_]                   |\W     |[[^A-Za-z0-9_]
+|(...)  |分组保存为 $1..$9               |\.     |对元字符的转义
+
+“替换”自动可以使用 $1..$9 作为对“查找”字段中括号中内容的反向引用。
+----
+示例:\\
+
+查找 __/abc|def/__ 会匹配单词 'abc' 或 'def'\\
+查找 __/bwiki/b__ 会匹配 'wiki' 但不匹配 'jspwiki'。\\
+查找 __^[[IVXMDCL]+\.__ 会匹配任意组合的罗马数字以及紧跟其后的句点 '.'\\
+查找 __/(-?\d+)(\d{3})/__ 并用 __$1,$2__ 替换会在大的数字中插入逗号 ','。
+
+这个是 [EditFindAndReplaceHelp] 页面。
+[更多关于正则表达式的信息|http://www.regular-expressions.info/javascript.html]
+以及 [RegExp 沙盒|http://www.regular-expressions.info/javascriptexample.html]\\

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditPageHelp.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditPageHelp.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditPageHelp.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/EditPageHelp.txt Mon Nov 10 19:49:06 2008
@@ -1,35 +1,35 @@
-ËøôÈáåÂàóÂá???ÜÊÇ®ÂèØ?ª??ªªÊÑè??øÁî®ÁöÑÂÖÉÁ¥?Ôºö
-{{{
-----             Ê?¥Â??ÂàÜÈöîÁ?ø
-\\               º?Âà?Êñ?Ë°å
-[link]           Âàõª? "link" ÁöÑË?ÖÈìæÊé?ÔºåÂÖ???? "link" ÂèØ?ª?ÊòØÂÜÖÈÉ® Wiki ÂêçÁß?ÔºàWiki È°µÈù¢
-                 ÂêçÁß?ÔºâÊàñËÄÖ§ñÈÉ®ÈìæÊé?Ôºàhttp://Ôºâ
-[text|link]      Âàõª???Ä???ÊòæÁ§?ÊñáÊú¨ÂíåÂÆûÈôÖË?ÖÈìæÊé???çÂêåÁöÑË?ÖÈìæÊé?ÔºåÂÖ?????Äútext?Äù???˶ŠÊòæÁ§?ÁöÑÊñáÊú¨Ôºõ?Äúlink?Äù???ÂÆûÈôÖÁöÑË?ÖÈìæÊé??ÄÇ
-[text|wiki:link] Âàõª???Ä???ÊòæÁ§?ÊñáÊú¨ÂíåÂÆûÈôÖË?ÖÈìæÊé???çÂêåÁöÑË?ÖÈìæÊé?Ôºå
-                 Â????îË?ÖÈìæÊé?ÊåáÂêëÊåáÂÆöÁöÑ WikiÔºàÊØî如 JSPWiki?ÄÅMediaWiki Á?âÁ?âÔºâ?ÄÇ
-                 ËøôÁßçÈìæÊé?ÊîØÊåÅ Wiki ??ãÈó¥ÁöÑÈìæÊé??ÄÇ
-
-*                Âàõª???Ä???È°?ÁõÆÂàóË°®ÔºàÊòüÂè? '*' ÂøÖÈúÄ???ÊâÄÂú®Ë°åÁ¨¨??Ä???Â?óÁ¨¶Ôºâ?ÄÇÁî®ËøûÁª?§ö???ÊòüÂè?Ôºà**Ôºâ
-                 Ë°®Á§?ʨ°Á?ßÈ°?ÁõÆÁ¨¶Âè??ÄÇ
-#                Âàõª???Ä???ÁºñÂè?ÂàóË°®ÔºàÊòüÂè? '*' ÂøÖÈúÄ???ÊâÄÂú®Ë°åÁ¨¨??Ä???Â?óÁ¨¶Ôºâ?ÄÇÁî®ËøûÁª?§ö???ÔºÉÂè?Ôºà##Ôºå###Ôºâ
-                 Ë°®Á§?Áº©Ëøõ/ʨ°Á?ßÁºñÂè??ÄÇ
-
-!, !!, !!!       Âú®Ë°åȶñÂä???äÊÑüÂè?Âè?ÔºàÔºÅÔºâÁîüÊàêÊ?áÈ¢ò?ÄÇ
-                 ÊÑüÂè?Âè?Ë?ä§öË°®Á§?Ê?áÈ¢òË?ä§ß?ÄÇ
-
-__text__         ÊñáÊú¨Âä?Á?ó?ÄÇ
-''text''         ÁªôÊñáÊú¨Êñú??ìÊïàÊûúÔºàÊ?®ÊÑèÊòØÂçïºïÂè? 'Ôºâ
-{{text}}         ??øÊñáÊú¨Âèò???Á?âʨæÂ?ó??ì?ÄÇ
-;term:def        Áî® 'def' ÂÆö??â 'term'?ÄÇÁî®Á©?ÁöÑ 'term' ÂèØ?ª?Ë°®Á§?ÁÆÄÁü?Ê?®ÈáäÔºà¶ÇÔºå;:Created on 2008/02/28Ôºâ?ÄÇ
-
-|text|more text ÁîüÊàêË°®Ê?º?ÄÇ??§Êù°Á´ñÁ?ø?Äú||?ÄùË°®Á§?Ë°®Ê?ºÊ?áÈ¢ò?ÄÇ
-}}}
-
-??ç˶ÅÂ?ùËØï??øÁî® HTML Ê?áËÆ?ÔºåHTML Ê?áËÆ?Âú®ËøôÈáå??ç˵???úÁî®?ÄÇ
-
-˶ŵåÂÖ?ÂõæÂÉèÔºåÂè?ÈúÄ˶ÅÂ?Ü?ªñ?ª¨?ª?ÂÖÅËÆ?ÁöÑÊ?ºÂºèÊîæÂú®Á?ë??äÔºåÁÑ?Âêé?ªñ?ª¨?ºöËá?Âä®ÊèíÂÖ??ÄÇ˶ÅÊü?ÁúãÂÖÅËÆ?ÁöÑÂõæÂÉèÊ?ºÂºèÂàóË°®ÔºåËØ?ÂèÇÈòÖ [Á?ªÁªü?ø°ÊÅØ|SystemInfo]?ÄÇ
-
-˶ÅÂàõª??ª£Á?ÅÂùóÔºå??øÁî® 3 ???Â?¶Ëä±Êã¨Âè? '{' ºÄÂßãÔºå3 ???Âè?Ëä±Êã¨Âè? '}' ÁªìÊùü?ÄÇ
-
-''ÔºàÊÉ?Áü?ÈÅìËøôÊƵÊñáÊú¨?ªéÂì?ÈáåÊù?ÔºüËøôÊƵÊñáÊú¨Âú®??Ä???Âè´ [ÁºñËæëÈ°µÈù¢Â?ÆÂä©|Edit Page Help]ÔºåËøô???È°µÈù¢?????üÂèØ?ª?ÁºñËæëÔºÅÔºâ''
-
+这里列出了您可以任意使用的元素:
+{{{
+----             水平分隔线
+\\               强制断行
+[link]           创建 "link" 的超链接,其中 "link" 可以是内部 Wiki 名称(Wiki 页面
+                 名称)或者外部链接(http://)
+[text|link]      创建一个显示文本和实际超链接不同的超链接,其中“text”为要 显示的文本;“link”为实际的超链接。
+[text|wiki:link] 创建一个显示文本和实际超链接不同的超链接,
+                 并且超链接指向指定的 Wiki(比如 JSPWiki、MediaWiki 等等)。
+                 这种链接支持 Wiki 之间的链接。
+
+*                创建一个项目列表(星号 '*' 必需为所在行第一个字符)。用连续多个星号(**)
+                 表示次级项目符号。
+#                创建一个编号列表(星号 '*' 必需为所在行第一个字符)。用连续多个#号(##,###)
+                 表示缩进/次级编号。
+
+!, !!, !!!       在行首加上感叹号(!)生成标题。
+                 感叹号越多表示标题越大。
+
+__text__         文本加粗。
+''text''         给文本斜体效果(注意是单引号 ')
+{{text}}         使文本变为等款字体。
+;term:def        用 'def' 定义 'term'。用空的 'term' 可以表示简短注释(如,;:Created on 2008/02/28)。
+
+|text|more text 生成表格。两条竖线“||”表示表格标题。
+}}}
+
+不要尝试使用 HTML 标记,HTML 标记在这里不起作用。
+
+要嵌入图像,只需要将他们以允许的格式放在网上,然后他们会自动插入。要查看允许的图像格式列表,请参阅 [系统信息|SystemInfo]。
+
+要创建代码块,使用 3 个左花括号 '{' 开始,3 个右花括号 '}' 结束。
+
+''(想知道这段文本从哪里来?这段文本在一个叫 [编辑页面帮助|Edit Page Help],这个页面你也可以编辑!)''
+

Modified: incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/FullRecentChanges.txt
URL: http://svn.apache.org/viewvc/incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/FullRecentChanges.txt?rev=712929&r1=712928&r2=712929&view=diff
==============================================================================
--- incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/FullRecentChanges.txt (original)
+++ incubator/jspwiki/branches/JSPWIKI_2_9_STRIPES_BRANCH/src/wikipages/zh_CN/FullRecentChanges.txt Mon Nov 10 19:49:06 2008
@@ -1,3 +1,3 @@
-Ëøô??õÊòØÂØ?ÊâÄÊúâÈ°µÈù¢ÂÅöÁöÑ?øÆÊî??ÄÇÁü???Ä??õÁöÑÂàóË°®ÂèØ?ª?Âú® [RecentChanges] ???ÊâæÂà??ÄÇ
-
-[{INSERT com.ecyrd.jspwiki.plugin.RecentChangesPlugin}]
+这些是对所有页面做的修改。短一些的列表可以在 [RecentChanges] 中找到。
+
+[{INSERT com.ecyrd.jspwiki.plugin.RecentChangesPlugin}]



Mime
View raw message