title: Dynamically replace HTML element in UIWebView
body: <p>I have some HTML loaded in WebView like this:  </p>
  
  <pre><code>&lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;before  &lt;myTag&gt;Content&lt;/myTag&gt;  after&lt;/body&gt;&lt;/html&gt;
  </code></pre>
  
  <p>I want to replace element <code>myTag</code> with custom text so it should look like:</p>
  
  <pre><code> &lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;before  ____MY_CUSTOM_TEXT___  after&lt;/body&gt;&lt;/html&gt;
  </code></pre>
  
  <p>Also I can't change initial HTML. 
  How I can do this with JavaScript?</p>
  
  <p>My not finished code:</p>
  
  <pre><code>var elements = document.getElementsByTagName( 'myTag' );
  var firstElement = elements[0];
  var parentElement = firstElement.parentNode;
  var html = parentElement.innerHTML;
  parentElement.innerHTML = html.replace(?????, '____MY_CUSTOM_TEXT___');
  </code></pre>
  
  <p>I don't know how to get string value of element to replace (?????).</p>