Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我可以以某种方式将 JSF、Jboss 配置?faces-redirect=true为每个链接的默认使用吗?还是我必须为我正在写的每个链接指定这个?
?faces-redirect=true
泰
?faces-redirect=true仅当您想在 POST 之后发出 GET 请求时才需要重定向后缀,例如从支持 bean 操作方法。对于通过 GET 的“正常”链接,您应该使用h:linkorh:button代替。
h:link
h:button
您可以在 faces-config.xml 中的导航案例中指定 <redirect/>。