this code is strange !


Posted on 16th Feb 2014 07:03 pm by admin

Hi i got this code from the web.. It checks for live and dead socks
It is working perfectly on my localhost. but does not work in any webserver ! any ideas ?


<?php
$filename = "proxies.txt"; //or a localpath.
$rel=file_get_contents($filename);
$ipset = explode("n",$rel); // explode it based on your delimiter.
foreach($ipset as $ips)
{
$ipandport=explode(':',$ips);
//Porxy string format might be 123.156.189.112:8080
$host=$ipandport[0];
$i=(int)$ipandport[1];
$fp = @fsockopen("tcp://".$host,$i,$errno,$errstr,10);
// tcp:// because, socks4 uses TCP and socks5 uses TCP & UDP
if($fp)
{
echo("Result is $fp");
echo ("port " . $i . " open on " . $host . "");
fclose($fp);
}
flush();
}
?>


Waiting for replies....

No comments posted yet

Your Answer:

Login to answer
255 Like 10 Dislike
Previous forums Next forums
Other forums

Problem with Sending Mail by PHP
hello all,
I m new to php, can u plz provide me the code to send mail by php having CAPTC

Is it a good practice to store user info. in sessions?
I am making a user class for my script which stores all the user information in sessions. It takes u

PHP Captcha Error help - replace the "die" command
Hi All,

I am after a bit of help with a Captcha spam protection box.

The site gave me

Function
How can I make this function that once you click the link in the code it takes you to a new page wit

WHYISNT THIS MYSQL STATEMNT NOT WORKING? (php)
caps because its absolutely rediculous.
i dontunderstand why its not working. there is a column c

ereg_replace()
Basically what i need to do is

$title = "This Suck's"

$striped = ereg_repl

Last character removed
I have created a string from an array. I have inserted commas from my form values. I am trying to re

Keeping track of php uploads
Hello all.

I was looking at the way PHP handles file uploads.
It seems that PHP uses a tem

Execure stored procedure on a timer
Can someone tell me an easier way to execute a stored procedure on a timer? I am using Oracle 10g R

Why do I get this error?
Error:

Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash