voyent
Externalize icefaces javascript  XML
Forum Index -> Portals & Portlets
Author Message
fabio.spurio

Joined: 11/Aug/2010 09:05:03
Messages: 4
Offline


Hi, I have the need to separate static resources from dynamic resources. css, images, js have to be put in webserver and not application server.

So the problem is that i would like to externalize icefaces javascripts (e.g. ice-extras.js) and to specify to load them in jspx pages from a static position and not from icefaces servlet.

I hope, I've been clear. :)

Thanks in advance. Regards.

Fabio
alesky

Joined: 10/Jan/2010 00:00:00
Messages: 5
Offline


Ciao Fabio

actually i have your same requirements did you find a solution?
ted.goddard

Joined: 26/Oct/2004 00:00:00
Messages: 874
Offline


In general this would be possible, but it would likely require a number of code changes, including changes to CSS files. For instance, CSS files can contain references to images and other CSS files which are resolved at runtime through embedded EL expressions in the CSS (assuming that JSF 2 is being used). These references do not need to be calculated each time the file is served, though, and a tool could be implemented that would pre-calculate all of the references. Certain images, such as those generated by a chart component, cannot be served statically.

Unfortunately, it would not be possible to just map javax.faces.resource to the static location as ICEpush, for instance, uses the JSF resource API as an extension mechanism. On the other hand, each specific static resource in the application could likely be mapped, and performing the lookup in the mapping table would not be a significant performance burden (no more than looking for files on the filesystem).

Can you describe your reasons for requiring this? Even though all resources could not be served in this way, perhaps a sufficient subset could be addressed.
[Email]
 
Forum Index -> Portals & Portlets
Go to:   
Powered by JForum 2.1.7ice © JForum Team