org.meshcms.taglib
Class Editor

java.lang.Object
  extended byjavax.servlet.jsp.tagext.TagSupport
      extended byorg.meshcms.taglib.AbstractTag
          extended byorg.meshcms.taglib.Editor
All Implemented Interfaces:
javax.servlet.jsp.tagext.IterationTag, com.opensymphony.module.sitemesh.RequestConstants, java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class Editor
extends AbstractTag

This tag must include all others in a theme file. This is required to enclose all other tags in an HTML form while editing the page. Usually this tag is the first child of <body>:

 <body><cms:editor>
     ... (html and other MeshCMS tags) ...
 </cms:editor></body>
Important note: since a form can't be enclosed in another form, you must surround any other form in your theme with a <cms:ifnotediting> tag:
 <body><cms:editor>
     ... (html and other MeshCMS tags) ...
         <cms:ifnotediting><form action='youraction'>
             ... your form ...
         </form></cms:ifnotediting>
     ... (html and other MeshCMS tags) ...
 </cms:editor></body>
This way your form won't be displayed while editing.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.meshcms.taglib.AbstractTag
PAGE_MODULES, PARAM_REGEX
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface com.opensymphony.module.sitemesh.RequestConstants
DECORATOR, FILTER_APPLIED, PAGE, ROBOT, USING_STREAM
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
Editor()
           
 
Method Summary
 int doEndTag()
           
 int getStartTagReturnValue()
          Defines the return value of doStartTag().
 void writeEditTag()
          Writes the contents of the tag when the page is being edited.
 void writeTag()
          Writes the contents of the tag.
 
Methods inherited from class org.meshcms.taglib.AbstractTag
doStartTag, getHead, getMailFormAddress, getOut, getPage
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Editor

public Editor()
Method Detail

doEndTag

public int doEndTag()

writeTag

public void writeTag()
              throws java.io.IOException
Description copied from class: AbstractTag
Writes the contents of the tag. Subclasses will use this method to write to the page.

Specified by:
writeTag in class AbstractTag
Throws:
java.io.IOException

writeEditTag

public void writeEditTag()
                  throws java.io.IOException
Description copied from class: AbstractTag
Writes the contents of the tag when the page is being edited. The default implementation calls writeTag(). Subclasses can override it when they behave differently while editing.

Overrides:
writeEditTag in class AbstractTag
Throws:
java.io.IOException

getStartTagReturnValue

public int getStartTagReturnValue()
Description copied from class: AbstractTag
Defines the return value of doStartTag(). This method can be overridden by subclasses to change that value. The default implementation returns SKIP_BODY.

Overrides:
getStartTagReturnValue in class AbstractTag
See Also:
AbstractTag.doStartTag()