title: How do I set URL for WebView from layout XML in Android?
body: <p>I'm trying to set the URL for a WebView from the layout main.xml.</p>
  
  <p>By code, it's simple:</p>
  
  <pre><code>WebView webview = (WebView)findViewById(R.id.webview);
  webview.getSettings().setJavaScriptEnabled(true);
  webview.loadUrl("file:///android_asset/index.html");
  </code></pre>
  
  <p>Is there a simple way to put this logic into the layout XML file?</p>