Skip navigation

Jive Release Blog

3 Posts authored by: nick Employee
nick

Clearspace 2.0 Public Beta 4

Posted by nick Employee Mar 18, 2008

The fourth update to the public beta has just been released. Thanks to all your activity in the community the past few weeks, we have resolved over 200 issues since the first public beta. We encourage all of you using a previous version of the beta to download the latest and let us know what you think.

 

Same as before, the best place to contribute is in the Clearspace Beta space. You can download the new beta releases from your Jive Software website account where you find other releases.

 

Documentation for the new beta release is available here and includes upgrade information.

 

Thanks again for all your questions, comments, and feedback over the past few weeks!

Configuring your action to use the freemarker result type

 

  • Freemarker views are rendered via the webwork result type freemarker, or by using the dispatcher result type in conjunction Webwork's FreemarkerServlet.

  • We use the freemarker result type which is defined in xwork-community.xml, so you can simply use it like so:

 

<action name="test" class="package.Test">
    <result name="success" type="freemarker">
        /templates/testView.ftl
    </result> 
</action>

 

  • Since freemarker is defined as the default result type, type="freemarker" is not necessary when declaring your action.

 

Property Resolution

 

  • Your action properties are automatically resolved. FOR EXAMPLE:

 

${name} will result in stack.findValue("name"), which generally results in action.getName() being executed.

 

  • A search process is used to resolve the variable, searching the following scopes in order, until a value is found:

1.) Freemarker Variables 
2.) Webwork Value Stack 
3.) Request Attributes 
4.) Session Attributes 
5.) Servlet Context Attributes

 

 

Objects in the Context

 

  • Webwork objects added to the context

    • request - the current HttpServletRequest

    • response - the current HttpServletResponse

    • stack - the current OgnlValueStack

    • ognl - the OgnlTool instance. This class contains useful methods to execute OGNL expressions against arbitary objects

    • webwork ? an instance of FreemarkerWebWorkUtil

    • action - the current WebWork action

    • exception - optional the Exception instance, if the view is a JSP exception or Servlet exception

 

  • Jive objects added to the context

    • JiveGlobals

    • JiveConstants

    • LocaleUtils

    • StringUtils

    • DateUtils

    • SkinUtils

    • Permissions

    • IMSettingsUtils

    • ActionUtils

    • RSSActionSupport

    • ViewCountManager

    • CommunityUtils

    • BlogUtils

    • FeedUtils

    • WikiUtils

    • LicenseManager

    • DocumentPermHelper

    • MessagePermHelper

 

${JiveGlobals.getJiveProperty(?skin.defaultHeader?)?default(?Community Home?)}

 

  • In addition, static models and enums can be referenced as so:

 

${statics('com.jivesoftware.community.action.CommunityAction').VIEW_OVERVIEW}
${enums('com.jivesoftware.community.SearchQueryCriteria$SortType').RELEVANCE.key?c}
where ) is replaced with ] and ( is replaced with [

 

Clearspace 1.10 was released yesterday and includes a number of minor bug fixes and improvements. Be sure to checkout the changelog if you are interested in what has changed.

 

We are going to continue putting out releases for the Clearspace 1.x series, but from this point forward they will only contain bug fixes and minor improvements. All new feature development has been moved to Clearspace 2.0, which will be available at the end of Q1 2008.

Filter Blog

By date: By tag: