looks like this was lifted from here http://stackoverflow.com/questions/5454910/international-count-sms-characters --> http://jsfiddle.net/puKJb/

generally good practice when you find some code on the internet and use it to make a comment with a link so that it's clear where it came from / that it might not be completely understood.