使用wicket框架渲染基本标记的方法有哪些?
在JSP中,我可以这样做:
<base href="${pageScope.contextPath}/" />
答案 0 :(得分:5)
在YourPage.html中:
<head>
...
<base wicket:id="base"/>
...
</head>
在YourPage.java中:
WebComponent base = new WebComponent("base");
add(base);
base.add(new AttributeModifier("href", "<the url>"));