Well, Thanks for this.
I used it on my IPB forum, its working fine for most of the hosts explained in the js.
but its not working for extabit and manually added hosts/