title: Selenium Java Webdriver: Adding a string to an Xpath
body: <p>I have the folllowing piece of Java in which I want to add a String <em>inside</em> a statement:</p>
  
  <pre><code>     @and ("^I want to change fieldnumber \"([^\"]*)\" , remove whats inside and add the following text: \"([^\"]*)\"$")
  
      public void testscenario12345(String number,  String text) throws Throwable {
      driver.findElement(By.xpath("//*[contains(@name,'template:view:&lt;INSERT NUMBER STRING HERE&gt;:item:view:1:item:')]")).clear();
      driver.findElement(By.xpath("//*[contains(@name,'template:view:&lt;INSERT NUMBER STRING HERE&gt;:item:view:1:item:')]")).sendKeys(text);
  </code></pre>
  
  <p>How can I add the number string in the above piece of code? To clarify, If I insert "4" in cucumber, I want the driver to find the element by Xpath, where the @name contains template:view:4:item:view:1:item:</p>