The following is the code I tried to get "id" value from the currently loaded URL in webview
Uri uri = Uri.parse(webView.getUrl()); String server = uri.getAuthority(); String path = uri.getPath(); String protocol = uri.getScheme(); Set<String> args = uri.getQueryParameterNames(); String chapter = uri.getQueryParameter("id");
Which gives no error, but the app crashes on loading!
Original code was
Uri uri = Uri.parse("http://www.chalklit.in/post.html?chapter=V-Maths-Addition%20&%20Subtraction&post=394");
1.4m articles
1.4m replys
5 comments
57.0k users