adding indexOf for ie8