title: Open camera for input type file in Webview not opening Android
body: <p>I a newbie in android. I am creating a small app to take photo and upload it to server. I am using Webview and html form do that. In browser (chrome) camera is opening. But in webview, camera is not opened when "choose file" is clicked. Anyone know a solution? Below is the code i used....</p>
  
  <p>HTML Code</p>
  
  <pre><code>&lt;html&gt;
  &lt;body&gt;
  &lt;form&gt;
  &lt;input type="file" accept="image/*;capture=camera"/&gt;
  &lt;input type="submit"/&gt;
  &lt;/form&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Java code used in Android (eclipse)</p>
  
  <pre><code>public class MainActivity extends Activity {
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
  
      WebView myWebView = (WebView) findViewById(R.id.webview);
      myWebView.setWebViewClient(new WebViewClient());
      WebSettings webSettings = myWebView.getSettings();
      webSettings.setJavaScriptEnabled(true);
      myWebView.loadUrl("http://www.inforge.in/thejus/test.html");
  }       
  
  
  @Override
  public boolean onCreateOptionsMenu(Menu menu) {
      // Inflate the menu; this adds items to the action bar if it is present.
      getMenuInflater().inflate(R.menu.main, menu);
      return true;
  }
  
  @Override
  public boolean onOptionsItemSelected(MenuItem item) {
      // Handle action bar item clicks here. The action bar will
      // automatically handle clicks on the Home/Up button, so long
      // as you specify a parent activity in AndroidManifest.xml.
      int id = item.getItemId();
      if (id == R.id.action_settings) {
          return true;
      }
      return super.onOptionsItemSelected(item);
  }
  </code></pre>
  
  <p>}</p>