title: how can i get the content of a class in selenium webdriver?
body: <p><strong>code :</strong></p>
  <pre><code>from selenium import webdriver
  from selenium.webdriver.chrome.options import Options
  
  
  options = webdriver.ChromeOptions()
  options.add_argument(r&quot;--user-data-dir=C:\Users\bji\AppData\Local\Google\Chrome\User Data&quot;) #e.g. C:\Users\You\AppData\Local\Google\Chrome\User Data
  options.add_argument(r'--profile-directory=Default') #e.g. Profile 3
  driver = webdriver.Chrome(executable_path=r'C:\Users\bji\Downloads\chromedriver_win32(1)\chromedriver.exe', chrome_options=options)
  
  
  
  
  
  
  driver.get('wanted website')
  
  content = driver.find_element_by_xpath('//*[@id=&quot;__layout&quot;]/div/div[2]/div[1]/div[1]/div/div[2]/ul/li[1]/a/div[3]/div[2]/div/p')
  
  
  if ( content == 24 ) :
      content.click()
  </code></pre>
  <p><strong>and this my html code :</strong></p>
  <pre><code>&lt;p data-v-d31307be=&quot;&quot; class=&quot;tw-ml-2 text__green&quot;&gt;24&lt;/p&gt;
  </code></pre>