Search code examples
webspherewebsphere-portal

How to discover pages where portlet appears?


I want to get programmatically all pages (or one) where portlet is presented on Webspehe portal. Actualy can't find any information about my issue.


Solution

  • The available SPI really was not designed to work back up the chain like this you can go from layoutcontrol to portletwindow to portletdefinition to portlet

    So the ugly way to do this would be to get the content model, loop over all page types, get the layout model for the page, then get the layout controls, from those get the portlet windows, and then go to portlet definition.

    The shorter way is to iterate over a full xmlaccess and parse and build the list that way. I did write a whitepaper on how to get the layout controls on the page ftp://public.dhe.ibm.com/software/dw/lotus/Controller_Model_SPI_Final.pdf