Web Analytics Made Easy -
StatCounter External URL Request - CodingForum

Announcement

Collapse
No announcement yet.

External URL Request

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • External URL Request

    I have a list of e-mail addresses which I want to unsubscribe (example.com replaces our real url):

    PHP Code:
    foreach ($final_list as $value){
    $value2=rawurlencode($value);
    $url1="http://example.com/?q=direct_unsub&fn=Public_DirectUnsubForm&id=bjtwytqttkhejtfrmnxswcevupwgbln&email=$value2";
    $ch curl_init($url1);
    curl_setopt($chCURLOPT_HEADER0);
    curl_exec($ch);
    curl_close($ch);

    Is this the best way to do this? I'm getting some garbled text on the return value. Is there a way to send the request without getting a return value?

  • #2
    I'm not sure how the CURL functions work. What I use if I need to send a request like this is the include() function, though it requires output buffering to handle/ignore the output/return value of the request.

    Comment

    Working...
    X