ie 8 compatibility, replace indexOf method
Merge pull request #46 from huei90/patch-1

ie 8 compatibility, replace indexOf method