added marker
fixed bug:
when search for the second time, the result is not correct by resetting the resultArray for each time the mainPageCtrl is initialized.