Sprache / SDK
WeProxy-Proxy-Einrichtung Für PHP
Der übliche Weg für WeProxy in PHP ist cURL. Kein Composer-Paket nötig. Host, Port und Zugangsdaten aus der Umgebung laden und die Exit-IP prüfen.
The most common way to use WeProxy in PHP is cURL. No Composer package is required — only the curl extension. This short guide shows how to verify your exit IP through an HTTP proxy with host, port, and credentials.
Requirements
- PHP 8.0+ with the
curlextension (curlshould appear inphp -m) - Host, port, username, and password from the WeProxy panel
Do not hard-code credentials. Keep them in environment variables.
export WEPROXY_HOST="gw.weproxy.com.tr"
export WEPROXY_PORT="8989"
export WEPROXY_USER="PROXY_USERNAME"
export WEPROXY_PASSWORD="PROXY_PASSWORD"
HTTP Proxy with cURL
<?php
$host = getenv('WEPROXY_HOST') ?: 'gw.weproxy.com.tr';
$port = getenv('WEPROXY_PORT') ?: '8989';
$user = getenv('WEPROXY_USER') ?: '';
$pass = getenv('WEPROXY_PASSWORD') ?: '';
$ch = curl_init('https://api.ipify.org');
curl_setopt($ch, CURLOPT_PROXY, $host . ':' . $port);
curl_setopt($ch, CURLOPT_PROXYUSERPWD, $user . ':' . $pass);
curl_setopt($ch, CURLOPT_PROXYTYPE, CURLPROXY_HTTP);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 20);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
echo curl_exec($ch);
If your package supports SOCKS5 and the panel enables it, set CURLOPT_PROXYTYPE to CURLPROXY_SOCKS5.
GitHub example
See the runnable sample, env setup, and short README in weproxy-io/php-proxy.
Sources
Weitere Integrationen
Ein anderes Tool im Blick?
Jetzt Starten
Jetzt mit WeProxy verbinden
Konto erstellen, 100 MB kostenlosen Residential-Traffic sofort nutzen und die Schritte oben in Ihrer eigenen Einrichtung umsetzen.










