To participate, please log in to your Andromo App Maker account then come back here!

how to hide url?

I want to know if there is any way to hide the url of a web activity, when the user does not have internet, to avoid revealing the url address and that the user leaves our app and connects directly to a new site. :'(

Or that the competition is aware of the source of your information.  ;)

Comments

  • If the user doesn't has internet, they won't be able to install ur apps in the first place.


  • Create Your Own App with Andromo


  • meghak, I refer to this type of activity and obviously the user has to have downloaded the app but if he loses his connection to the internet, he could avoid revealing the url of the information source. 
    example: https://ibb.co/is67s9

    Is there any way to hide the url? @darryl @colinadams @lorne
  • Thanks for the suggestion. We'll see what we can do in a future release.
  • edited October 2018
    @colinadams any update about this??
  • Hi @colinadams,

    I would to ask about the update of hiding url. I've tried to search about hiding webview activity, how can andromo implement this code? This is from http://www.vetbossel.in/android-webview-webpage-not-available/

    ------------------------------------------------------------------------------------------

    package com.example.ourapps.webapplication;
     
    import android.content.DialogInterface;
    import android.graphics.Bitmap;
    import android.support.v7.app.AlertDialog;
    import android.support.v7.app.AppCompatActivity;
    import android.os.Bundle;
    import android.webkit.WebView;
    import android.webkit.WebViewClient;
    import android.widget.Toast;
     
    public class MainActivity extends AppCompatActivity {
     
        private WebView webView;
        @Override
        protected void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.activity_main);
     
            webView = (WebView) findViewById(R.id.webView);
            webView.setWebViewClient(new myWebClient());
            webView.getSettings().setJavaScriptEnabled(true);
            webView.loadUrl("https://www.ourwebsite.com");
     
            webView.setWebViewClient(new WebViewClient() {
                public void onReceivedError(WebView webView, int errorCode, String description, String failingUrl) {
                    try {
                        webView.stopLoading();
                    } catch (Exception e) {
                    }
     
                    if (webView.canGoBack()) {
                        webView.goBack();
                    }
     
                    webView.loadUrl("about:blank");
                    AlertDialog alertDialog = new AlertDialog.Builder(MainActivity.this).create();
                    alertDialog.setTitle("Error");
                    alertDialog.setMessage("Check your internet connection and try again.");
                    alertDialog.setButton(DialogInterface.BUTTON_POSITIVE, "Try Again", new DialogInterface.OnClickListener() {
                        public void onClick(DialogInterface dialog, int which) {
                            finish();
                            startActivity(getIntent());
                        }
                    });
     
                    alertDialog.show();
                    super.onReceivedError(webView, errorCode, description, failingUrl);
                }
            });
        }
     
        public class myWebClient extends WebViewClient
        {
            @Override
            public void onPageStarted(WebView view, String url, Bitmap favicon) {
                super.onPageStarted(view, url, favicon);
            }
     
            @Override
            public boolean shouldOverrideUrlLoading(WebView view, String url) {
     
                view.loadUrl(url);
                return true;
     
            }
        }
     
        @Override
        // This method is used to detect back button
        public void onBackPressed() {
            if(webView.canGoBack()) {
                webView.goBack();
            } else {
                // Let the system handle the back button
                super.onBackPressed();
            }
        }
    }

    ---------------------------------------------------------------------------------------------------------
    Thank you for your concern
Sign In or Register to comment.