Comments (4)
from youdaotranslator.
看这个样子是你机器的代理出错了, 不是 alfred 的问题。
from youdaotranslator.
Hi, 抱歉再次打扰到您。
/**
* 组装请求地址
* @return String
*/
private function getQueryUrl($query)
{
$api = 'http://fanyi.youdao.com/openapi.do?type=data&doctype=json&version=1.1&';
$key = $this->keys[array_rand($this->keys)];
$key['q'] = $query;
return $api.http_build_query($key);
}
我看了下源文件,其中有这么一段定义请求相关信息的地方。
抱歉不会php,我猜最后句应该是发起请求的。
不知道是否是其中哪个参数可以自定义下发起请求的ip:port
alfred 本身的代理我也是有配置的,但不是127.0.0.1:80,
所以我猜是不是php中如果没有指定发起HTTP请求的端口,默认就直接走了本机的80端口去请求?
from youdaotranslator.
你贴出来的函数只是组装了一个地址, 然后是用的 curl 去请求这个地址。
现在请求这个地址的时候,自动跑到了 127.0.0.1:80 , 说明Surge 已经把代理拿过去了。
alfred 已经走到代理这里了。 我没用过 Surge , 感觉应该是 Surge 规则设置的有问题。 你可以去 Surge 论坛群组里去问一问。
from youdaotranslator.
Related Issues (20)
- 翻译报错
- ID失效
- 翻译速度延迟大 HOT 1
- 有计划支持下Raycast么,免费开源版的Alfred
- Passing output '' to Script Filter HOT 5
- 直接翻译选中内容无法使用 HOT 4
- 翻译过快导致有道api支付价格高昂 HOT 4
- 在结果可以增加打开有道app并查询详细的操作吗? HOT 1
- 突然无法使用了,提示network request failed 网络问题
- 无法正常运行script HOT 10
- 使用无效,搜索不会显示有道 HOT 2
- 设置查询间隔 HOT 3
- Alfred 3 无法翻译
- m2版本 运行错误 HOT 5
- 如果是因为系统更新导致的不可用,贡献一个修复方式
- 访问频率受限是什么原因 HOT 4
- alfred 5 版本好像用不了 HOT 1
- m3处理器好像用不了
- 如何让在线发言速度慢一些?
- yd 结果返回异常, 现在只能返回一行内容了吗? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from youdaotranslator.