表单 – 带URL操作的JSF表单?

有没有办法在< h:commandButton>中调用URL操作,或者是< h:form>?我正试图从我自己的网站绕过我的电子邮件登录页面,所以我使用JSF bean来保存我的登录信息< h:inputSecret>标签,以便我可以简单地点击“转到电子邮件”,因为我已登录到我自己的网站,我可以直接进入我的收件箱,无需再次登录 最佳答案 只需使用纯
HTML< form>而不是JSF< h:form>.

<form action="http://example.com/mail" method="post">
    <input type="text" name="username" value="#{bean.username}" />
    <input type="password" name="password" value="#{bean.password}" />
    <input type="submit" value="Go to Email" />
</form>
点赞