Sorry, something went wrong.
We're working on getting this fixed as soon as we can.
Go Back
El código es este:
Código:
Alguien que haya trabajado con esto me puede ayudar? <?php $app_id = EL_ID_DE_LA_APLICACION_EN_NUMEROS; $canvas_page = "http://miurl.com/app/"; $auth_url = "http://www.facebook.com/dialog/oauth?client_id=" . $app_id . "&redirect_uri=" . urlencode($canvas_page); $signed_request = $_REQUEST["signed_request"]; list($encoded_sig, $payload) = explode('.', $signed_request, 2); $data = json_decode(base64_decode(strtr($payload, '-_', '+/')), true); if (empty($data["user_id"])) { echo("<script> top.location.href='" . $auth_url . "'</script>"); } else { echo ("Welcome User: " . $data["user_id"]); } ?>