-
1. Re: GateIn with JQuery
trong.tran Jul 20, 2010 12:01 AM (in response to funkybreizh)1 of 1 people found this helpfulYou could be able to configure it by XML in the gatein-resources.xml file in your war, for an example ( http://anonsvn.jboss.org/repos/gatein/portal/tags/3.1.0-GA/web/eXoResources/src/main/webapp/WEB-INF/gatein-resources.xml ) :
<javascript> <param> <js-module>moduleName</js-module> <js-path>/path/to/file.js</js-path> <js-priority>10</js-priority> </param> </javascript>
with that, GateIn will imports your js library by default in page's header
Ensure your {WAR}/WEB-INF/web.xml file includes following filter
<filter> <filter-name>ResourceRequestFilter</filter-name> <filter-class>org.exoplatform.portal.application.ResourceRequestFilter</filter-class> </filter> <filter-mapping> <filter-name>ResourceRequestFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping>
-
2. Re: GateIn with JQuery
funkybreizh Jul 20, 2010 3:20 PM (in response to trong.tran)Yes, it's work, but what about the css theme of JQuery. I try something like this :
Write my own skin, for my portal, based on the SimpleSkin :
And in Stylesheet.css, I have :
My custom theme css is well load, but the jquery theme is not.
any idea?
[Edit] The css is load, but not the images, for example in my css it's :
But in my navigator, it's :
Is it the filter, or something like that?
-
3. Re: GateIn with JQuery
trong.tran Jul 21, 2010 12:02 AM (in response to funkybreizh)the WEB-INF/gatein-resources.xml file is a registration for Javascript and CSS in a WAR to GateIn portal ( refers http://docs.jboss.com/gatein/portal/3.1.0-FINAL/reference-guide/en-US/html_single/index.html#sect-Reference_Guid-Skin_Configuration-Skin_Service )
So you could do same way with CSS by something like this :
<portal-skin> <skin-module>JQuery</skin-module> <skin-name>Default</skin-name> <css-path>/JQuery/ui-lightness/jquery-ui-1.8.2.custom.css</css-path> <overwrite>false</overwrite> </portal-skin>
-
4. Re: GateIn with JQuery
funkybreizh Jul 21, 2010 10:03 AM (in response to trong.tran)<skin-module> doesn't exist in the gatein-ressource dtd !
And it doesn't work
-
5. Re: GateIn with JQuery
trong.tran Jul 21, 2010 12:52 PM (in response to funkybreizh)1 of 1 people found this helpful<skin-module> doesn't exist in the gatein-ressource dtd !
Yes, it was missing in the gatein_resources_1_0 dtd and updated in gatein_resources_1_1 ( Look at JIRA issue https://jira.jboss.org/browse/GTNPORTAL-1316 )
And it doesn't work
What happened ?
-
6. Re: GateIn with JQuery
funkybreizh Jul 21, 2010 3:31 PM (in response to trong.tran)Thanks, the css is well load in my head's page, but images aren't display even if urls define in the css are good, they aren't load in the page.
-
7. Re: GateIn with JQuery
trong.tran Jul 21, 2010 10:13 PM (in response to funkybreizh)Could you show us the file structure in your war and the content of gatein-resources.xml file ?