Author: julien(a)jboss.com
Date: 2007-02-12 17:46:02 -0500 (Mon, 12 Feb 2007)
New Revision: 6237
Modified:
docs/trunk/referenceGuide/en/modules/cmsPortlet.xml
Log:
started to rework CMS portlet chapter
Modified: docs/trunk/referenceGuide/en/modules/cmsPortlet.xml
===================================================================
--- docs/trunk/referenceGuide/en/modules/cmsPortlet.xml 2007-02-12 22:43:14 UTC (rev
6236)
+++ docs/trunk/referenceGuide/en/modules/cmsPortlet.xml 2007-02-12 22:46:02 UTC (rev
6237)
@@ -53,13 +53,12 @@
.
</para>
<programlisting><![CDATA[
- <portlet-preferences>
- <preference>
- <name>indexpage</name>
- <value>/default/index.html</value>
- </preference>
- </portlet-preferences>]]>
- </programlisting>
+<portlet-preferences>
+ <preference>
+ <name>indexpage</name>
+ <value>/default/index.html</value>
+ </preference>
+</portlet-preferences>]]></programlisting>
<para>
The preference key is "indexpage". To change the default page, just
make sure to create
an html document using the CMS Admin portlet then change the value of
"indexpage" to
@@ -77,13 +76,13 @@
<literal>portal-cms.sar/META-INF-INF/jboss-service.xml</literal>
</para>
<programlisting><![CDATA[
- ...
- <attribute name="DoChecking">true</attribute>
- <attribute
name="DefaultContentLocation">portal/cms/conf/default-content/default/</attribute>
- <attribute name="DefaultLocale">en</attribute>
- <attribute
name="RepositoryName">PortalRepository</attribute>
- <attribute
name="HomeDir">${jboss.server.data.dir}${/}portal${/}cms${/}conf</attribute>
- ]]></programlisting>
+...
+<attribute name="DoChecking">true</attribute>
+<attribute
name="DefaultContentLocation">portal/cms/conf/default-content/default/</attribute>
+<attribute name="DefaultLocale">en</attribute>
+<attribute name="RepositoryName">PortalRepository</attribute>
+<attribute
name="HomeDir">${jboss.server.data.dir}${/}portal${/}cms${/}conf</attribute>]]>
+...</programlisting>
<para>Below is a list of items found in the service descriptor and
their definitions. Only
items commonly changed are covered here and it is recommended you do not
change any others
unless you are very brave.</para>
@@ -124,22 +123,20 @@
and change the value of Prefix to something else. Please note that you
cannot change it to "nothing", you
need to provide a value.
</para>
- <programlisting>
- <![CDATA[
- ...
- <mbean
- code="org.jboss.portal.core.cms.CMSObjectCommandFactory"
- name="portal:commandFactory=CMSObject"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- <attribute name="Prefix">content</attribute>
- <attribute
name="TargetWindowRef">default.default.CMSPortletWindow</attribute>
- <depends optional-attribute-name="Factory"
proxy-type="attribute">portal:commandFactory=Delegating</depends>
- <depends optional-attribute-name="CMSService"
proxy-type="attribute">portal:service=CMS</depends>
- </mbean>
- ...
- ]]>
+ <programlisting><![CDATA[
+...
+<mbean
+ code="org.jboss.portal.core.cms.CMSObjectCommandFactory"
+ name="portal:commandFactory=CMSObject"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+ <attribute name="Prefix">content</attribute>
+ <attribute
name="TargetWindowRef">default.default.CMSPortletWindow</attribute>
+ <depends optional-attribute-name="Factory"
proxy-type="attribute">portal:commandFactory=Delegating</depends>
+ <depends optional-attribute-name="CMSService"
proxy-type="attribute">portal:service=CMS</depends>
+</mbean>
+...]]>
</programlisting>
<itemizedlist>
<listitem>
@@ -319,79 +316,74 @@
It works the same way as the server interceptor, for each interceptor you
need to define an mbean then add it
to the cms interceptor stack. For example, if you have the 2 default
interceptors, you should have the following
lines in the jboss-service.xml file:
- <programlisting>
- <![CDATA[
- <mbean
- code="org.jboss.portal.cms.impl.interceptors.LogInterceptor"
- name="portal:service=Interceptor,type=Cms,name=Log"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- </mbean>
- <mbean
- code="org.jboss.portal.cms.impl.interceptors.CacheInterceptor"
- name="portal:service=Interceptor,type=Cms,name=Cache"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- <depends>portal:service=CMSTreeCache</depends>
- </mbean>
- <mbean
- code="org.jboss.portal.server.impl.invocation.JBossInterceptorStack"
- name="portal:service=InterceptorStack,type=Cms"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- <depends-list optional-attribute-name="InterceptorNames">
-
<depends-list-element>portal:service=Interceptor,type=Cms,name=Log</depends-list-element>
-
<depends-list-element>portal:service=Interceptor,type=Cms,name=Cache</depends-list-element>
- </depends-list>
- </mbean>
- ]]>
+ <programlisting><![CDATA[
+<mbean
+ code="org.jboss.portal.cms.impl.interceptors.LogInterceptor"
+ name="portal:service=Interceptor,type=Cms,name=Log"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+</mbean>
+<mbean
+ code="org.jboss.portal.cms.impl.interceptors.CacheInterceptor"
+ name="portal:service=Interceptor,type=Cms,name=Cache"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends>portal:service=CMSTreeCache</depends>
+</mbean>
+<mbean
+ code="org.jboss.portal.server.impl.invocation.JBossInterceptorStack"
+ name="portal:service=InterceptorStack,type=Cms"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends-list optional-attribute-name="InterceptorNames">
+
<depends-list-element>portal:service=Interceptor,type=Cms,name=Log</depends-list-element>
+
<depends-list-element>portal:service=Interceptor,type=Cms,name=Cache</depends-list-element>
+ </depends-list>
+</mbean>]]>
</programlisting>
The first two mbeans define the interceptors and the third mbean, define
which interceptors to add to
the CMS service.
</para>
<para>
If you create your own interceptor
<literal>org.example.myCMSInterceptor</literal>, the service descriptor file
will look like:
- <programlisting>
- <![CDATA[
- <mbean
- code="org.example.myCMSInterceptor"
- name="portal:service=Interceptor,type=Cms,name=MyName"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- </mbean>
- <mbean
- code="org.jboss.portal.cms.impl.interceptors.LogInterceptor"
- name="portal:service=Interceptor,type=Cms,name=Log"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- </mbean>
- <mbean
- code="org.jboss.portal.cms.impl.interceptors.CacheInterceptor"
- name="portal:service=Interceptor,type=Cms,name=Cache"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- <depends>portal:service=CMSTreeCache</depends>
- </mbean>
- <mbean
- code="org.jboss.portal.server.impl.invocation.JBossInterceptorStack"
- name="portal:service=InterceptorStack,type=Cms"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
- <xmbean/>
- <depends-list optional-attribute-name="InterceptorNames">
-
<depends-list-element>portal:service=Interceptor,type=Cms,name=Log</depends-list-element>
-
<depends-list-element>portal:service=Interceptor,type=Cms,name=Cache</depends-list-element>
-
<depends-list-element>portal:service=Interceptor,type=Cms,name=MyName</depends-list-element>
- </depends-list>
- </mbean>
- ]]>
- </programlisting>
+ <programlisting><![CDATA[
+<mbean
+ code="org.example.myCMSInterceptor"
+ name="portal:service=Interceptor,type=Cms,name=MyName"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+</mbean>
+<mbean
+ code="org.jboss.portal.cms.impl.interceptors.LogInterceptor"
+ name="portal:service=Interceptor,type=Cms,name=Log"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+</mbean>
+<mbean
+ code="org.jboss.portal.cms.impl.interceptors.CacheInterceptor"
+ name="portal:service=Interceptor,type=Cms,name=Cache"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends>portal:service=CMSTreeCache</depends>
+</mbean>
+<mbean
+ code="org.jboss.portal.server.impl.invocation.JBossInterceptorStack"
+ name="portal:service=InterceptorStack,type=Cms"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.common.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends-list optional-attribute-name="InterceptorNames">
+
<depends-list-element>portal:service=Interceptor,type=Cms,name=Log</depends-list-element>
+
<depends-list-element>portal:service=Interceptor,type=Cms,name=Cache</depends-list-element>
+
<depends-list-element>portal:service=Interceptor,type=Cms,name=MyName</depends-list-element>
+ </depends-list>
+</mbean>]]></programlisting>
</para>
<note>
<para>