php - Send email with proxy IP using CURLOPT_CONNECT_ONLY -
what problem here? can't send email server different ip address (for example proxy here).
warning: curl_setopt() expects parameter 2 long, string given in [link] on line 12
<? $ch = curl_init(); curl_setopt($ch, curlopt_proxy, "103.10.22.242"); curl_setopt($ch, curlopt_proxyport,3128); curl_setopt($ch, curlopt_connect_only,true); curl_exec($ch); echo curl_error($ch); $to = "you@your-domainname.com"; $nameto = "who to"; $from = "script@your-domainname.com"; $namefrom = "who from"; $subject = "hello world again!"; $message = "world, hello!"; mail($from, $namefrom, $to, $nameto, $subject, $message); ?>
an ip address can represented single number. googled ip long converter , found this.
the equivalent long value ip 1728714482.
Comments
Post a Comment