We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
最近打算使用saber来作为twitter api 的客户端,发现saber会自动对url进行转码.导致api请求失败.
经过测试发现: 使用 SaberGM::get("http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url");
SaberGM::get("http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url");
服务端接收到经过转码的QUERY_STRING: [QUERY_STRING] => max_results=10&tweet_fields=lang%2Ccreated_at%2Centities&expansions=attachments.media_keys&media_fields=type%2Cpreview_image_url%2Curl
[QUERY_STRING] => max_results=10&tweet_fields=lang%2Ccreated_at%2Centities&expansions=attachments.media_keys&media_fields=type%2Cpreview_image_url%2Curl
而用curl 发送请求: curl "http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url" 服务端能接收到正确的QUERY_STRING: [QUERY_STRING] => max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url
curl "http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url"
[QUERY_STRING] => max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url
请问如何禁止saber对url自动转码?
The text was updated successfully, but these errors were encountered:
服务器端不能urldecode一下吗?这里是参照guzzle的一个实现
Sorry, something went wrong.
服务器的处理不是我能控制的, 使用guzzle(7.4) 测试 并没有这个问题 根据RFC3986中指定了以下字符为保留字符:! * ' ( ) ; : @ & = + $ , / ? # [ ] 希望大大修复一下
No branches or pull requests
最近打算使用saber来作为twitter api 的客户端,发现saber会自动对url进行转码.导致api请求失败.
经过测试发现:
使用
SaberGM::get("http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url");
服务端接收到经过转码的QUERY_STRING:
[QUERY_STRING] => max_results=10&tweet_fields=lang%2Ccreated_at%2Centities&expansions=attachments.media_keys&media_fields=type%2Cpreview_image_url%2Curl
而用curl 发送请求:
curl "http://127.0.0.1/r.php?max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url"
服务端能接收到正确的QUERY_STRING:
[QUERY_STRING] => max_results=10&tweet.fields=lang,created_at,entities&expansions=attachments.media_keys&media.fields=type,preview_image_url,url
请问如何禁止saber对url自动转码?
The text was updated successfully, but these errors were encountered: