Don't use innerHTML for setting children, it was causing issues in IE
refactor autocomplete script and add it to header