Need assistance using phones back button to go back in Webview
This is my code: package com.testappmobile; import android.app.Activity; import android.os.Bundle; import android.view.KeyEvent; import android.view.Window; import android.webkit.WebChromeClient; import android.webkit.WebView; import android.webkit.WebViewClient; public class testappmobileActivity extends Activity { final Activity activity = this; private WebView webview; @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // Check if the key event was the BACK key and if there's history if ((keyCode == KeyEvent.KEYCODE_BACK) && webview.canGoBack()) { webview.goBack(); return