3

I have converted google website into Web app for android using webview_flutter: ^1.0.7 package when I run the code in my physical device by making it external emulator the app work perfectly but when I build the APK using flutter build apk --release I got the the APK file and when I install the APK after opening the application it say Web page not available you can see the image below. I think it was not able to connect through internet enter image description here

and when I install the app by making my device emulator it run perfectly you can see below

enter image description here

if you need more information regarding this please comment.

MOHAMMAD ZEESHAN
  • 273
  • 3
  • 15
  • Can you show your manifest file and Your code too? – Rahul Pandey Jun 03 '22 at 06:34
  • @RahulPandey you can see the important codes here https://codesandbox.io/s/flutter-ui-builder-forked-uql57f?file=/lib/AndroidManifest.xml – MOHAMMAD ZEESHAN Jun 03 '22 at 07:12
  • @RahulPandey if you need more code i can give you there – MOHAMMAD ZEESHAN Jun 03 '22 at 07:13
  • 1
    @MOHAMMADZEESHAN , I don't see Internet permission in your Manifest file, Can you please add the same and test. Reference link on how/where to add - [why-cant-a-flutter-application-connect-to-the-internet-when-installing-app-release](https://stackoverflow.com/questions/55603979/why-cant-a-flutter-application-connect-to-the-internet-when-installing-app-rel) – Nitish Jun 03 '22 at 08:14
  • 1
    @MOHAMMADZEESHAN Add Internet Permission In Your Manifest File and see if it works if not than we need to check your dart file – Rahul Pandey Jun 03 '22 at 08:34
  • Thankyou @RahulPandey now my app is running – MOHAMMAD ZEESHAN Jun 03 '22 at 08:53

1 Answers1

1

android\app\src\main\AndroidManifest.xml Add internet permission

examble :

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.example.test">

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

   <application
        android:label="test1"
        android:name="${applicationName}"
        android:icon="@mipmap/ic_launcher">

Visit this page for more information INTERNET PERMISSION

Shamil
  • 74
  • 3