3 Replies Latest reply on May 11, 2008 11:42 AM by Radu Cirstoiu

    Portlet deploying on multiple pages

    Radu Cirstoiu Newbie

      Hi
      I'm writing a portlet and I decided to create a new page where to display it by adding the "" (-object.xml) inside a "" tag.
      The new page is created fine, but the portlet is not removed from the old page (default page at first, then inside any window I specify in <window-name>).

      Is this a bug, or am I missing something?

        • 1. Re: Portlet deploying on multiple pages
          Peter Johnson Master

          The portal layout is kept within a database. Once a portlet is placed on a page via the *-object.xml file, the only way to remove the portlet from that page is to use the management porltet (log on as admin and go to the admin portal). Changing the location of the portlet using the *-object.xml file will not remove the portlet from the old location.

          • 2. Re: Portlet deploying on multiple pages
            Pavel Myshkin Newbie

            Generally in order to "clear" the DB entries for deployments of a certain page you have to notice that the tag <if-exists> has the value "overwrite" and not "keep".

            If it is overwrite then redeployment of your webapp will reinitialize that page or portal with all the children which are configured in the deployed -object.xml

            Anyway FYI:

            one portal can have * pages,
            one page can have * pages,
            one page also can have * windows,
            one portlet instance can have * windows,
            one portlet name can have * portlet instances.

            Hope this helps

            • 3. Re: Portlet deploying on multiple pages
              Radu Cirstoiu Newbie

              Thanks for both replies!
              I do have the "overwrite" option but somehow the whole thing isn't refreshed.
              But that's fine with me for now.
              Also if I come to think about it, it would be a hard task to refresh the portal correctly as changes can be made via a deployment descriptor as well as from an administrator.

              Thank you both again.