define echoTabInfo and set locationchange hook