Easiest way to launch webpage in android with an icon

后端 未结 8 723
北荒
北荒 2021-02-03 11:02

We have a website that offers an e-mail service. We would like to create a fully fledged app for this but cannot afford this right now. In the mean time it would be great if we

相关标签:
8条回答
  • 2021-02-03 11:42

    I have done projects like this in the past, it is very simple. You need to create a website formatted for a smaller screen. Once you do this, building an android app that displays your website inside it is simple. You can even remove all of the android browser toolbars so it appears as if your website is a real android application. Google android webviews, this will point you in the right direction.

    0 讨论(0)
  • 2021-02-03 11:43

    See here for what's probably the best instruction page on how to do exactly that:

    http://intelnav.50webs.com/app_project.html

    It's based on a Webview, that is it opens the page and does all the navigation in the app window, not in the default browser. So if you want to open it in the browser, you have to use Intent, as said in previous answers.

    My 2 pennies worth, I think it's better in the app window unless you really want complex navigation with the possibility of opening additional tabs, windows and so on. The drawback with the external browser is that, as far as I could see, there's no way to tell if the page is already open in the browser so you'll launch a different copy (in a new tab) every time. If the user doesn't close the tab at the end, they usually don't, it can become quite annoying. Besides, within an app you'll probably have somewhat better possibilities for ads should you ever want them.

    Versus a simple home-screen bookmark, as others pointed out, it's simpler and more convenient for end users to just download an app from an online store (usually Google Play). It's what they're used to do. And they do have a lot of additional info available, like what it does, what others say about it, screen shots (if you provide some for them but you should). Plus a way to comment / complain themselves. It's a different thing. Technically it may not make a lot of sense but from a simple user's perspective it's clearly better IMO.

    0 讨论(0)
  • 2021-02-03 11:50

    Create a new Android project (after following the SDK installation steps provided at http://developer.android.com)

    on the directory /res/drawable-*dpi you have the laucher icons. Modify all of them.

    In the main activity, delete all inside the onCreate method an put this:

    String url = "http://www.YOUR-URL.com";
    Intent i = new Intent(Intent.ACTION_VIEW);
    i.setData(Uri.parse(url));
    startActivity(i);
    

    This will open the android browser with the URL provided.

    0 讨论(0)
  • 2021-02-03 11:53

    One way is to bookmark the site and then add it to your home screen. Source

    0 讨论(0)
  • 2021-02-03 11:53

    It seems to me like you need a mobile version of your web page. Do you have that already? Once you have your mobile website (ie. website optimized for mobile devices), you could create a simple application with only one WebView. All content would be fetched from your site and displayed inside a webview. This is trivial to make, however, making an entire mobile website will take some time.
    Note that you do not HAVE TO have a mobile website, you could pack you existing website into a WebView, but this would lower user experience.

    0 讨论(0)
  • 2021-02-03 11:57

    Try this kick-start mobile device app for showing websites. Written with cordova for platforms like android, ios, browser and so on: https://github.com/jetedonner/ch.kimhauser.cordova.kickstartwebsite (GooglePlay: https://play.google.com/store/apps/details?id=ch.kimhauser.cordova.kickstartwebsite, Website: http://kimhauser.ch/index.php/projects/cordova-phonegap/kick-start-website)

    0 讨论(0)
提交回复
热议问题