Set returnUrl
How do I set the return URL when using the fb-login-button
? I want to redirect the current authe开发者_运维问答nticated user to another page (not the root (default.aspx))?
You can use the on-login
parameter of fb:login-button
to redirect to a different page.
This parameter can call a JavaScript function to perform the redirect, so you could do something like this:
<fb:login-button
on-login="RedirectLogon()"
/>
<script type="text/javascript">
function RedirectLogon {
window.location='nextpage.html'
}
</script>
Hope this helps.
精彩评论