--> How To Create A Simple Web Browsing App For Android? | Experience Lab - Online business creation and development guide for bloggers and startups

How To Create A Simple Web Browsing App For Android?

Did you know that you can create a basic web browsing android app for your website with just a few lines of code? Web browsing Android apps ...

How To Create A Simple Web Browsing App For Android?
Did you know that you can create a basic web browsing android app for your website with just a few lines of code? Web browsing Android apps are great if you have a nice website and you want to make your brand’s application with just a minimal amount of code. At the same time, it is a great way to learn more about Android application development, and it doesn't require a background in application development. So, in this tutorial, I will teach you how to create a basic web browsing app of your own!


Before moving on with this tutorial you should know, how to set up the SDK and must have understanding of creating a basic Android app. Here's what we've covered so far on the subject. Just bear with this tutorial, and if you have difficulty understanding a concept, then you can go back to any one of these previous tutorials.




Alright, let’s move on with the tutorial!

Creating a web browsing App for Android

Step 1: Create a new Android Application project


Using Eclipse create a new Android application project (“WebBrowsingApp”). For this tutorial I have selected API 16 (Jelly Bean).


New Project


Step 2: Edit activity_main.xml


Open “activity_main.xml” and add the following code:


<WebView  xmlns:android="http://schemas.android.com/apk/res/android"

    android:id="@+id/webview"

    android:layout_width="fill_parent"

    android:layout_height="fill_parent"

/>
Code


Step 3: Edit AndroidManifest.xml


Open “AndroidManifest.xml” and add the following code, after manifest tag:


<uses-permission android:name="android.permission.INTERNET" />


Code




Basically we’ve provided internet access to our application.


Step 4: Edit MainActivity.java


Finally edit “MainActivity.java”. Copy the following libraries:


import android.os.Bundle;

import android.annotation.SuppressLint;

import android.app.Activity;

import android.view.Menu;

import android.webkit.WebView;

import android.webkit.WebViewClient;


Now, overwrite the “public boolean onCreateOptionsMenu(Menu menu)” function with:


@SuppressLint("SetJavaScriptEnabled") @Override

public boolean onCreateOptionsMenu(Menu menu) {

// Inflate the menu; this adds items to the action bar if it is present.

        getMenuInflater().inflate(R.menu.activity_main, menu);

   

        WebView myWebView = (WebView) findViewById(R.id.webview);

        myWebView.setWebViewClient(new WebViewClient());

        myWebView.loadUrl("http://www.mybloggertricks.com");

          return true;

    }


Your MainActivity.java class should look like this;




Step 5: Execute



Now, it’s time to run our newly created web browsing app. Right click Project, and select Run as->Android application. It should look something like this.


Finished App


Pretty simple, right? You can add more functionality, and deliver your content in a much more optimized fashion to make your app much more mobile user-friendly.

COMMENTS

Name

Affiliate Marketing,12,Announcement,34,Bing,9,Bitcoin,38,blog,7,Blogger Resources,42,Blogger Templates,4,blogger tricks,156,Blogging ethics,70,Blogging tips,198,Bugs and Errors,34,Business,10,Copyright Violation,9,CSS and HTMLTricks,95,Designs,8,drop down menu,7,eBook,12,Email Marketing,7,Events,30,Facebook,30,Facebook tricks,49,Google,157,Google AdSense,42,Google Analytics,7,Google Plus,51,Google Plus Tricks,38,Guest Posts,112,home,2,How To,77,Internet,1,JSON Feeds,25,Kitchen Recipes,2,Label Based Sitemap Themes,1,Make Money Online,108,Marketing,17,MBT Blogger Templates,7,Menus,1,News,146,Pages,1,Posts,10,presentations,15,Responsive,10,Reviews,7,SEO,307,Settings,6,Shortcode,15,Sitemap Themes,1,Social Media,155,Technology,7,Templates,1,Tips,2,Tools,1,Traffic Tips,80,Video,19,Web Designing,62,web hosting,18,Webmaster Tools,97,Widgets,199,wordpress,26,
ltr
item
Experience Lab - Online business creation and development guide for bloggers and startups: How To Create A Simple Web Browsing App For Android?
How To Create A Simple Web Browsing App For Android?
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjdZ3pNugjr9hesqAeTVByPuxgT14shp_lAHZdkB-o8NoOQsNbngqwjt4B6likVyd4xgUApyPS1Moh_N71LDdrH3cY-IiCQ0ue6nG6Vmay2DrHEJ0BhZsJVeuJzZDf3NZQjjwOiB__eJNt-/s320/android+web+browsing+app.jpg
https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjdZ3pNugjr9hesqAeTVByPuxgT14shp_lAHZdkB-o8NoOQsNbngqwjt4B6likVyd4xgUApyPS1Moh_N71LDdrH3cY-IiCQ0ue6nG6Vmay2DrHEJ0BhZsJVeuJzZDf3NZQjjwOiB__eJNt-/s72-c/android+web+browsing+app.jpg
Experience Lab - Online business creation and development guide for bloggers and startups
https://www.experiencelab.info/2013/11/how-to-create-simple-web-browsing-app.html
https://www.experiencelab.info/
https://www.experiencelab.info/
https://www.experiencelab.info/2013/11/how-to-create-simple-web-browsing-app.html
true
2959477579779989044
UTF-8
Loaded All Posts Not found any posts VIEW ALL Readmore Reply Cancel reply Delete By Home PAGES POSTS View All RECOMMENDED FOR YOU LABEL ARCHIVE SEARCH ALL POSTS Not found any post match with your request Back Home Sunday Monday Tuesday Wednesday Thursday Friday Saturday Sun Mon Tue Wed Thu Fri Sat January February March April May June July August September October November December Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec just now 1 minute ago $$1$$ minutes ago 1 hour ago $$1$$ hours ago Yesterday $$1$$ days ago $$1$$ weeks ago more than 5 weeks ago Followers Follow THIS PREMIUM CONTENT IS LOCKED STEP 1: Share. STEP 2: Click the link you shared to unlock Copy All Code Select All Code All codes were copied to your clipboard Can not copy the codes / texts, please press [CTRL]+[C] (or CMD+C with Mac) to copy