title: How Keep website session in android webview
body: <p>I'm new to android developing. I just create an android app for my website using android webview. when i open my website from mobile browser first time it ask login details and once i logged in and close the browser without deleting cookies , then i open the browser again and visit my website it does not ask login again.</p>
  
  <p>But when I open my website from my webview app first time it ask login, when i logged in and close the webview app, and once again I open the app it ask me to login again. it ask me to login whenever i open this webview app. i want to maintain my website session like web browsers, how can i achieve this in android webview? </p>
  
  <p>my website has php, mysql login system.</p>
  
  <p>I just want to create an app like mobile browser</p>
  
  <p>my android code is </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.webView1);
  
      mywebview.setWebViewClient(new WebViewClient());
  
      mywebview.loadUrl("http://mywebsite.com/");
  
  
            }
  }
  </code></pre>