use String.indexOf() instead of String.search()