title: locating textbox in facebook messenger
body: <p>i am a noob python coder. i started learning selenium module and now i want to send a text using it but i am struggling to find textbox as the xpath of textbox is changing every time browser is refreshed</p>
  <pre><code>from selenium import webdriver
  import time
  
  i=1
  text=input(&quot;enter the text messege&quot;)
  chrome_options = webdriver.ChromeOptions()
  prefs = {&quot;profile.default_content_setting_values.notifications&quot; : 2}
  chrome_options.add_experimental_option(&quot;prefs&quot;,prefs)
  driver = webdriver.Chrome(chrome_options=chrome_options)
  #driver=webdriver.Chrome(r&quot;chromedriver&quot;)
  driver.get(r&quot;https://www.facebook.com/messages/t/2585929161530825/&quot;)
  time.sleep(7)
  email_box=driver.find_element_by_xpath(r'//*[@id=&quot;email&quot;]')
  email_box.click()
  email_box.send_keys(&quot;xnxx@gmail.com&quot;)
  time.sleep(3)
  password_box=driver.find_element_by_xpath(r'//*[@id=&quot;pass&quot;]')
  password_box.click()
  password_box.send_keys(&quot;rockyou.txt&quot;)
  time.sleep(3)
  login_button=driver.find_element_by_xpath(r'//*[@id=&quot;loginbutton&quot;]')
  login_button.click()
  time.sleep(10)
  '''remove_exception=driver.find_element_by_xpath(r'//*[@id=&quot;mount_0_0_DP&quot;]/div/div[1]/div/div[3]/div/div/div[1]/div[1]/div[2]/div/div/div/div/div/div[1]/div[2]/div/div/div/div[1]/div[1]/div/div/div[3]/div/div[15]/div[2]/div[3]/div/div/div/div[1]/div/div[1]/span/div/div')
  remove_exception.click()
  time.sleep(4)'''
  #pop_up=driver.find_element_by_xpath(r'')
  while i!=3000:
       chat_box=driver.find_element_by_class_name(r'ecm0bbzt e5nlhep0 buofh1pr jq4qci2q a3bd9o3v iko8p5ub eg9m0zos ni8dbmo4 rq0escxv lexh0w6q')
       chat_box.click()
       chat_box.send_keys(text,&quot;{}&quot;.format(i))
       send_button=driver.find_element_by_xpath(r'//*[@id=&quot;mount_0_0_Td&quot;]/div/div[1]/div/div[3]/div/div/div[1]/div[1]/div[2]/div/div/div/div/div/div[1]/div[2]/div/div/div/div[2]/div/form/div/div[3]/span[2]/div/svg')
       send_button.click()
       if(i==5):
            time.sleep(2)
       i+=1
  
  </code></pre>