Просмотр исходного кода

[브랜드][New] 소개 URL 교체 및 ssl error 처리

hyodong.min 7 лет назад
Родитель
Сommit
a498d3cd8c

+ 12 - 1
app/src/main/java/kr/co/zumo/app/lifeplus/view/screen/guide/LifeplusBrandFragment.java

@@ -1,14 +1,18 @@
 package kr.co.zumo.app.lifeplus.view.screen.guide;
 
+import android.net.http.SslError;
 import android.os.Bundle;
 import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
 import android.support.v4.app.Fragment;
 import android.support.v7.widget.RecyclerView;
+import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
+import android.webkit.SslErrorHandler;
 import android.webkit.WebView;
+import android.webkit.WebViewClient;
 
 import kr.co.zumo.app.R;
 
@@ -45,9 +49,16 @@ public class LifeplusBrandFragment extends Fragment {
 //    recyclerViewLifeplusX.setAdapter(lifeplusBrandAdapter);
 
     webView = getView().findViewById(R.id.web_view);
-    webView.loadUrl("https://timestore.lifeplus.co.kr/m/?utm_medium=etc&utm_source=official&utm_campaign=inn_trck");
+    webView.setWebViewClient(new WebViewClient() {
+      @Override
+      public void onReceivedSslError(WebView view, SslErrorHandler handler, SslError error) {
+        Log.w("APP# LifeplusBrandFragment | onReceivedSslError", "|" + "message: " + error.toString());
+        handler.proceed();
+      }
+    });
     webView.getSettings().setJavaScriptEnabled(true);
 
+    webView.loadUrl("https://lifeplus.app/resources/homepage/LP_introduce.html");
   }
 
 }