added function that search elements like jQuery