CURLOPT_PROXYPORT supplies a port number. It does not identify a proxy host, select a protocol or create a listener on the local machine.

A new PHP cURL configuration is easier to read when the complete endpoint stays together:

curl_setopt($handle, CURLOPT_PROXY, 'http://proxy.example:3128');

The libcurl documentation discourages the separate port option. Existing code can still use it with a host that has no embedded port:

curl_setopt($handle, CURLOPT_PROXY, 'http://proxy.example');
curl_setopt($handle, CURLOPT_PROXYPORT, 3128);

A port explicitly included in the proxy string takes precedence over the separate option. Avoid maintaining two conflicting numbers.

If only CURLOPT_PROXYPORT appears in a fragment, inspect the rest of the handle configuration and its applicable environment. The fragment alone does not reveal which proxy host, if any, libcurl will use.

Port 3128 is a familiar deployment choice, not a protocol detector. Use the listener’s real protocol and port. For a public HTTP route, the HTTP proxy list provides address-and-port candidates to keep together in the proxy URL. A proxy reachable on another port does not need to move merely to match an example.

འབྲེལ་བའི་རྩོམ་ཡིག