title: How to get value from Node in Selenium Webdriver and Print in Console?
body: <p>I have tried using Webelement to store value but
  facing Error like :
  [Below is the image of which I want to get value that is K1]</p>
  
  <p><a href="https://i.stack.imgur.com/iwquG.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/iwquG.png" alt="enter image description here"></a></p>
  
  <p>I am Not Getting value through Weblelement as It is displaying Error as </p>
  
  <pre><code>org.openqa.selenium.InvalidSelectorException: The given selector //div[2]/label/strong/following-sibling::text()
  is either invalid or does not result in a WebElement. 
  </code></pre>
  
  <p>I just want to store value in variable and print it, I have tried below code but no result :</p>
  
  <p>WebElement Key = driver.findElement(By.xpath("//div[2]/label/strong/following-sibling::text()"));
  String vs =Key.getText();
  System.out.println("key Name..!!!" + vs);</p>
  
  <p>Suggest Me Opinions</p>