From issues at jboss.org Mon May 4 05:43:46 2015 Content-Type: multipart/mixed; boundary="===============1393618836007750814==" MIME-Version: 1.0 From: Mehmet Salgar (JIRA) To: gatein-issues at lists.jboss.org Subject: [gatein-issues] [JBoss JIRA] (GTNPORTAL-3588) Possiblity to place JS in Portal Header Date: Mon, 04 May 2015 05:43:45 -0400 Message-ID: In-Reply-To: JIRA.12570588.1430732603000@Atlassian.JIRA --===============1393618836007750814== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Mehmet Salgar created GTNPORTAL-3588: ---------------------------------------- Summary: Possiblity to place JS in Portal Header Key: GTNPORTAL-3588 URL: https://issues.jboss.org/browse/GTNPORTAL-3588 Project: GateIn Portal Issue Type: Feature Request Components: WebUI Affects Versions: 3.6.0.Final Reporter: Mehmet Salgar Priority: Optional I am trying to use Atmosphere Framework with Gatein, Atmosphere relies self= calling javascript function to initialize itself. The application I try to build is a JSF application (with Portlet Bridge) a= nd for that reason JSF tries to include several javascript into the portlet. Unfortunately, one of them is jQuery (the others are jquery-plugins.js and = atmosphere.js) which contains a self calling function as constructor but wh= ile all the scripts are defined outside of the element, jQuery is no= t able to identify jquery-plugins and atmosphere self calling functions and= initialize them while they are out side of the elements. I read your documentation and they are claiming I have to use gatein-resour= ces,xml to be able to via requireJS but actually this is also not working a= nd these methods are never called. I need a direct configuration possibility to place these elements under the= element so javascript engine can call them. I found the following statement in one of your documents "The JSR286 specification provides a mechanism for modifying portal headers= that can be used to load JavaScript files. Although this mechanism is port= able, it has severe drawbacks: A script can be loaded multiple times, specially if two portlets in two dif= ferent war files load the same scripts since the only way to identify a scr= ipt is by its URL Scripts have to be loaded by the head section of the portal impacting front= end performances" via "org.gatein.javascript.dependency" but I can't make this to work also. So a direct possibility to add javascript to the head elements of portal wi= ll be really appreciated. -- This message was sent by Atlassian JIRA (v6.3.15#6346) --===============1393618836007750814==--