Adding a Page for the Tutorial Portlets

Now that you have created a new portlet, let's add a page to hold that portlet. In the jetexpress-portal project, add a folder to the root of our site named src/main/webapp/WEB-INF/pages/tutorial/. In addition to creating the folder, you will need to create a folder.metadata file:

<?xml version="1.0" encoding="UTF-8"?>
<folder>
  <title >Tutorial</title>  
  <metadata name="title" xml:lang="fr">Autodidacte</metadata>
  <security-constraints>
    <security-constraints-ref>public-edit</security-constraints-ref>
  </security-constraints>
</folder>

Then add a new page named default-page.psml under the tutorial directory. Add a portlet window to reference our new portlet:

<?xml version="1.0" encoding="UTF-8"?>
<page>
  <defaults layout-decorator="jetexpress" 
            portlet-decorator="jetexpress"
            skin="jetexpress"/>
  <title>JetExpress Tutorials</title>
  <short-title>Tutorials</short-title>
  <fragment id="tutorial-100" type="layout" name="jetspeed-layouts::VelocityTwoColumns">  
    <fragment id="express-101" type="portlet" name="jetexpress-pa::BonjourMonde"/>
  </fragment>
</page>

Stop Tomcat and deploy your portlet and the new pages:

mvn jetspeed:mvn -Dtarget=deploy-pa
mvn jetspeed:mvn -Dtarget=deploy-portal

After you restart Tomcat and log in to the portal, you will see the new tutorial page in the left menu:

Click on the tutorial link to see the new page with the BonjourMonde portlet:

Next

TODO

Previous - Next