title: How to load urls in the webview of second activity on button clicks
body: <p>i have two button on my first activity say A and i have a webview in my second activity say B
  now i want to load urls in webview on button click event.if i click on btn1 button then webview should show the google.com website , and if i click on the btn2 button then webview should show the gmail.com website,  here is my code for activity of A and B . thanks in advance</p>
  
  <p><strong>code for activity A</strong></p>
  
  <pre><code> Button btn1 = (Button) findViewById(R.id.btn_google);
              btn1.setOnClickListener(new OnClickListener() {
                   public void onClick(View v) {
                       Intent intent = new Intent (google.this,webview.class);
                       google.this.startActivity(intent);
  
                 }
                  }
  
                      );
  
               Button btn2 = (Button) findViewById(R.id.btn_gmail);
               btn_signup.setOnClickListener(new OnClickListener() {
                   public void onClick(View v) {
  
                      Intent intent = new Intent (google.this,webview.class);
                      google.this.startActivity(intent);
  
                 }
                  }
  
  
                  );
  </code></pre>
  
  <p><strong>here is the code of activity B</strong></p>
  
  <pre><code>super.onCreate(savedInstanceState);
            setContentView(R.layout.webview );
  
             WebViewClient yourWebClient = new WebViewClient()
             {
                 // Override page so it's load on my view only
                 @Override
                 public boolean shouldOverrideUrlLoading(WebView  view, String  url)
                 {
                  // This line we let me load only pages inside Firstdroid Webpage
                   view.loadUrl(url);
                     // Load new URL Don't override URL Link
  
                  // Return true to override url loading (In this case do nothing).
                  return true;
                 }
             };
  
  
             // Get Web view
             mWebView = (WebView) findViewById( R.id.mywebview ); //This is the id you gave 
             mWebView.getSettings().setJavaScriptEnabled(true);   
             mWebView.getSettings().setSupportZoom(true);       //Zoom Control on web (You don't need this 
                                                    //if ROM supports Multi-Touch      
             mWebView.getSettings().setBuiltInZoomControls(true); //Enable Multitouch if supported by ROM
             mWebView.setWebViewClient(yourWebClient);
             mWebView.reload();
  
  }
  </code></pre>