![](/img/trans.png)
[英]“The redirect_uri URL must be absolute” error on Facebook PHP SDK
[英]PHP, How to add php code inside redirect_uri?
我有一個 facebook 代碼:
<iframe src="http://www.facebook.com/plugins/registration.php?
client_id=138987726427834&
redirect_uri=https://xxx.com/login.php?login=<?php echo $login; ?>&pass=<?php echo $pass; ?>&
fields=<?php echo urlencode($fields);?>"
</iframe>
我想知道為什么$login
和$pass
在redirect_uri
內不起作用? 它們不會在鏈接內呈現。
我看到ields=<?php echo urlencode($fields);?>"
需要 php。
任何想法?
謝謝
你可能想用
redirect_uri=<?php echo urlencode("https://xxx.com/login.php?login={$login}&pass={$pass}"); ?>&
If you don't URL encode the URL, then you will send the parameters login
and pass
to registration.php
, not to login.php
.
此外,將密碼等敏感數據直接作為 GET 變量傳遞是一種不好的做法。 如果您必須通過 GET 發送密碼,您至少可以加密密碼。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.