Replace build-in 'trim' function with customer method as it is not supported in IE8 and earlier versions.
Merge pull request #25 from sergeykalenyuk/fixes

Replace build-in 'trim' function with custom method.