isaeken/proxier

PHP的Web代理

1.1.1 2023-05-13 18:36 UTC

This package is auto-updated.

Last update: 2024-09-13 22:22:15 UTC


README

一个简单的PHP Web代理。

安装

作为一个独立包

composer require isaeken/proxier

作为一个全局工具

composer global require isaeken/proxier

工具使用

proxier <url> --method=<method> --headers=<headers>

代理一个URL

proxier http://isaeken.com.tr

使用自定义HTML头代理一个URL

proxier http://isaeken.com.tr --headers="{'Content-Type': 'text/html'}"

使用自定义方法代理一个URL

proxier http://isaeken.com.tr --method=POST

代理一个URL并保存到文件

proxier http://isaeken.com.tr --output=index.html

使用

代理一个URL

use IsaEken\Proxier\Proxier;

$proxier = new Proxier();
$proxier->boot();
$proxier->proxyUsingGlobals('http://isaeken.com.tr');

注意

此包处于开发中,请勿在生产环境中使用。

许可

MIT许可(MIT)。请参阅许可文件获取更多信息。