I am using tiles but the css file of baselayout wont be applied on all pages

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-25 05:56:18

问题


the problem is that I have a css file that is pointed from my baselayout.jsp file as following, when I am in index.php it applies the css but when I move to Profile/view.jsp it does not.

when I look at the source I noticed it is looking the css file in Profile/stylesheets/Base.css rather than myproject/stylesheets/Base.css, how to point to it in a way that works on all pages.

   <link href="<s:url value="/stylesheets/mycss.css"/>" rel="stylesheet"
type="text/css" />

回答1:


Its a breeze, just change the address to solid address, as following

   http://www.example.com/myPreoject/stylesheets/Base.css


来源:https://stackoverflow.com/questions/14886588/i-am-using-tiles-but-the-css-file-of-baselayout-wont-be-applied-on-all-pages

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!