Travel Travel reports, it is all about food
Montreal: Schwartz's, Le Petit Alep
Albums: Pictures and some notes
ITRANS Song Book Hindi, Urdu, Marathi song lyrics
Online ITRANS Web Interface
BlockHosts block hosts
BlockHosts FAQ
BlockHosts Forum
CD Inserts & Envelopes Web Interface
Nisha Ganatra's Films
Cake: starring Heather Graham
Email: avinash@aczoom.com
Comments
Max execution time exceeded
In that case you are experiencing a warning "max_execution_time exceeded", you may put a .htaccess file into your blockhosts folder with this content:
php_value max_execution_time 90
Fix scripts
Downloaded the blocked_hosts.zip file. First the php files need the ^M removed. Use the dos2unix command.
In order for me to get the index.php working with the BlockHosts-2.4.0, I did the following:
change line 4 from
$file = "/etc/hosts.deny"
to$file = "/etc/hosts.allow"
change line 6 from
$blockline = "ALL"
to$blockline = "deny"
Most importantly, the command on line 33 is not very good with splitting a string using only 1 whitespace character. Instead, change line 33 from
$out[$i] = explode(" ",$output[$i])
to$out[$i] = preg_split('/\s+/',$output[$i])
This will split the array on any whitespace between characters and will file the table with ip addresses instead of blanks.
Finally in the file ip.class.php: be sure to make sure line 10 has the same file name for the iptocountry.csv as your file. I had to change it from ip2country.csv. Otherwise, the little flags will not show up.