Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-35061

Embeded portlet resources are not load on page first load.

    Details

      Description

      Runtime portlets embedded in dockbar, and theme do not have the js and css resources loaded when the page first load. top_head.jsp executes before the preferences are added by the embedded portlet.

      To reproduce:

      1)embed private-messaging portlet in a theme using runtime taglib.

      $velocityPortletPreferences.setValue("portletSetupShowBorders", "false")
      
      $theme.runtime("1_WAR_privatemessagingportlet", $velocityPortletPreferences.toString())
      
      $velocityPortletPreferences.reset()

      2)change the guest site to use the theme.
      3)on first load of the site you will see that private-messaging portlet embedded in the theme will not have the proper css, and javascript is not working
      4)reload the page again, Now the css is loaded and javascript is working this time.
      5)create a new page named "Page 2" under the same site.
      6) on first load of page 2, you will see that private-messaging portlet embedded in the theme will not have the proper css, and javascript is not working.
      7)reload page 2. Now the css is loaded and javascript is working again.

      -------------------------------------------------------------------------------------------

      Another finding I discovered is that portlets that are added to portal properties, portlet.add.default.resource.check.whitelist do not have the resources loaded on the page at all either no matter how many time you reload.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  6 years, 14 weeks ago

                  Packages

                  Version Package
                  6.2.0 CE M6