Google身份验证(弹出)
问题描述:
我已经自己弹出一个窗口来验证Google帐户。问题是,当我登录到任何谷歌账户时,它会关闭弹出窗口并且不会刷新具有打开弹出窗口链接的网页。是否有已经实施的解决方案?或者我真的需要自己实施一个?Google身份验证(弹出)
如果还有其他方法可以做,请告诉我。我有点绝望。
打开弹出:
<a href="#{request.contextPath}/home/convite/conviteGmail.jsf" onclick="showPopup(this.href);return(false);" >Gmail</a>
的弹出本身:
<h:outputLabel for="login" styleClass="email_convite">Login: </h:outputLabel>
<h:inputText id="login" value="#{conviteGmailBean.login}" />
</div>
<br/>
<div>
<h:outputLabel for="password" styleClass="email_convite">Password: </h:outputLabel>
<h:inputSecret id="password" value="#{conviteGmailBean.password}" />
</div>
<h:outputText value="#{conviteGmailBean.mensagemErro}" rendered="#{conviteGmailBean.erro}"/>
关闭弹出:
<a4j:commandLink action="#{conviteGmailBean.logarGmail}" oncomplete="javascript:window.close()" rendered="#{!conviteGmailBean.autenticado}" value="Login" reRender="convidarAmigosForm" />
答
我已经改变了关闭弹出部分:
<a4j:commandLink action="#{conviteGmailBean.logarGmail}" oncomplete="javascript:window.opener.parent.document.location.href='#{request.contextPath}/home/convite/convite.jsf';javascript:window.close()" rendered="#{!conviteGmailBean.autenticado}" value="Login" reRender="convidarAmigosForm" />
来源:
http://www.computing.net/answers/webdevel/reload-other-page-from-popup-window/1762.html