Login Register






developer wanted for a php script filter_list
Author
Message
RE: developer wanted for a php script #4
This is due to cloudfair protecting the site , file get contents does not set a user agent ect so is flagged by cloudfair we need to accept cookies also.

Using curl we can bypass this though..

Code:
<?php function FuckOffCloudFair($url) {    $ch = curl_init();    curl_setopt($ch,CURLOPT_USERAGENT,'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.13) Gecko/20080311 Firefox/2.0.0.13');    curl_setopt($ch, CURLOPT_COOKIEJAR, './cookies.txt');    curl_setopt($ch, CURLOPT_COOKIEFILE, './cookies.txt');    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);    curl_setopt($ch, CURLOPT_HEADER, false);    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);    curl_setopt($ch, CURLOPT_URL, $url);    curl_setopt($ch, CURLOPT_REFERER, $url);    curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);    $result = curl_exec($ch);    curl_close($ch);    return $result; }                 $html = FuckOffCloudFair('https://leakforums.net/bans.php?pq=1');     $pattern = '/[a-z0-9_\-\+]+@[a-z0-9\-]+\.([a-z]{2,3})(?:\.[a-z]{2})?/i'; preg_match_all($pattern, $html, $matches); foreach($matches[0] as $emailaddress){ $message = "hello"; mail($emailaddress, 'Subject', $message); print "Sent email to " . $emailaddress . "<BR>"; } ?>


Gives us:

[Image: GIoNh5G.png]

If I was you I would insert each email address to a mysql database with a unique column on the addreess , then check the mysql database using a SELECT/num_rows statement to see if a email is already there before emailing the person. This will prevent you emailing the same person twice.

P.S this might attract a bunch of scammers to any forum you are directing people too , so just keep that in mind!
(This post was last modified: 04-30-2017, 04:21 PM by Darkbyte.)

Reply





Messages In This Thread
developer wanted for a php script - by hacxx - 04-29-2017, 04:01 PM
RE: developer wanted for a php script - by hacxx - 04-30-2017, 01:18 PM
RE: developer wanted for a php script - by Darkbyte - 04-30-2017, 03:19 PM
RE: developer wanted for a php script - by hacxx - 04-30-2017, 04:39 PM
RE: developer wanted for a php script - by hacxx - 04-30-2017, 05:23 PM
RE: developer wanted for a php script - by hacxx - 04-30-2017, 05:55 PM
RE: developer wanted for a php script - by hacxx - 04-30-2017, 08:48 PM
RE: developer wanted for a php script - by hacxx - 05-02-2017, 08:48 PM