I'm using the following package: jboss-portal-2.0-jboss-4.0.2 out of the box.
I'm trying to reuse ContentPortlet. It's working in portal-core, but not in my own .war.
I have defined the following:
In portlet.xml:
<portlet> <portlet-name>OwnContentPortlet</portlet-name> <portlet-class>org.jboss.portal.core.portlet.cms.ContentPortlet</portlet-class> <supports> <mime-type>text/html</mime-type> <portlet-mode>VIEW</portlet-mode> </supports> <portlet-info> <title>Content</title> </portlet-info> <portlet-preferences> <preference> <name>uri</name> <value>/default/testpage.html</value> </preference> </portlet-preferences> </portlet> And *pages.xml: <pages> <portal-name>default</portal-name> <page> <page-name>hello</page-name> <window> <window-name>HelloPortletWindow</window-name> <instance-ref>hello.HelloPortlet.HelloPortletInstance</instance-ref> <region>left</region> <height>0</height> </window> <window> <window-name>ContentPortletWindow</window-name> <instance-ref>hello.OwnContentPortlet.ContentPortletInstance</instance-ref> <region>center</region> <height>0</height> </window> </page> </pages>
The ContentPortlet is trying to find the file "testpage.html". I assume that this file does not exist. That is why you are getting the 404 error.
Try creating the file using the AdminCMS.