This content has been marked as final.
Show 4 replies
-
1. Re: Visual Editor: Problem with stylesheet path and multiple
maxandersen Nov 10, 2008 2:03 AM (in response to asgeirf)if you are using JBT 3 beta you should be able to setup a EL expression for the pages in a specific folder.
See http://docs.jboss.org/tools/whatsnew/vpe/vpe-news-3.0.0.Alpha1.html for details. -
2. Re: Visual Editor: Problem with stylesheet path and multiple
asgeirf Nov 10, 2008 2:51 AM (in response to asgeirf)"max.andersen@jboss.com" wrote:
if you are using JBT 3 beta you should be able to setup a EL expression for the pages in a specific folder.
See http://docs.jboss.org/tools/whatsnew/vpe/vpe-news-3.0.0.Alpha1.html for details.
Great, thanks!
This seems to work fine for images etc, but I can't get it to work for CSS.
1) Setting the actual run-time absolute folder (pr project) to my 'view' folder
2) Setting the el expression (pr project) request.contextPath to empty string (no value)<img src="#{request.contextPath}/img/banner.png"/> <link rel="stylesheet" type="text/css" href="#{request.contextPath}/stylesheet/theme.css"/>
(I'm on #jbosstools on IRC if you'd like to help debug this further) -
3. Re: Visual Editor: Problem with stylesheet path and multiple
asgeirf Nov 10, 2008 6:35 PM (in response to asgeirf)Some further observations regarding this issue:
Observation 1) The visual editor in a clean JBoss Tools install (In my case this build [1] on linux_x86_64) does not pick up the stylesheet of a clean seam-gen project generated by the 'seam create-project' command.<a:loadStyle src="/stylesheet/theme.css"/>
To test this, change the url to '../stylesheet/theme.css' and you will see that the page is rendered with the stylesheet (this relative url naturally only works for layout/template.xhtml and co, change it to e.g. 'stylesheet/theme.css' to see the change in 'home.xhtml')
Observation 2) Setting the 'Actual Run-time Absolute folder' to $myproject/view in Project-scope does not help resolve the CSS url above.
Max opened this and related jiras yesterday: https://jira.jboss.org/jira/browse/JBIDE-3059
However, this issue might not be directly related to EL expressions, as I don't use any in this example, and it still doesn't work...
[1] http://download.jboss.org/jbosstools/builds/nightly/3.0.0.CR1/200811080256/index.html -
4. Re: Visual Editor: Problem with stylesheet path and multiple
maxandersen Nov 11, 2008 4:46 AM (in response to asgeirf)the problem is that for seam-gen'ed project we don't know the root web content dir.
I guess we should add a "search upwards until we see a WEB-INF dir...that would be a good default.