title: WebView and MathML
body: <p>I have tried putting MathML code into a WebView and it doesn't render properly. What am I doing incorrectly?</p>
  
  <pre><code>import android.app.Activity;
  import android.os.Bundle;
  import android.webkit.WebView;
  
  public class HelloWebView extends Activity {
  WebView mWebView;
  String mathml = "&lt;html&gt;&lt;body&gt;&lt;math xmlns=\"http://www.w3.org/1998/Math/MathML\"&gt;&lt;mrow&gt;&lt;msup&gt; &lt;mi&gt;x&lt;/mi&gt; &lt;mn&gt;2&lt;/mn&gt; &lt;/msup&gt;&lt;/mrow&gt;&lt;/math&gt; END OF TEST&lt;/body&gt;&lt;/html&gt;";
  
  /** Called when the activity is first created. */
  @Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.main);
  
      mWebView = (WebView) findViewById(R.id.webview);
      mWebView.getSettings().setJavaScriptEnabled(true);
      mWebView.loadData(mathml, "text/html", "utf-8");
     }
  }
  </code></pre>