add search by using api instead of basic html