0

I successfully automated logging in to linkedin, but I have not been able to successfully interact with the search bar. I keep getting "'list' object has no attribute 'click'". My code is copied below. I tried skipping the click method to see if I could pass information into the searchbar object, but that yielded the same error. The xpath is directly copied from chrome developer tools.

def linkedin_search():
    searchbar = driver.find_elements_by_xpath('//*[@id="ember41"]/input')
    searchbar.click()
    searchbar.send_keys("Real Estate Investor")
    searchbar.send_keys(Keys.ENTER)
linkedin_search()

2 Answers2

0

I don't think you actually need the click() method. Try just sending keys.

Frank
  • 459
  • 2
  • 9
0

Well, it turns out I just needed to use the find_element_by_xpath rather than find_elements_by_xpath. That one s changes how the object is treated. I should've done more research before posting this question...