Page 332 - MDP2022-2
P. 332

import  androidx.appcompat.app.AppCompatActivity;


            public  class  MainActivity  extends  AppCompatActivity  {
                    Button  btn_threeidiotscoding;
                    Button  mv_shop;


                    @Override
                    protected  void  onCreate(Bundle  savedInstanceState)  {
                            super.onCreate(savedInstanceState);
                            setContentView(R.layout.activity_main);


                            btn_threeidiotscoding  =  findViewById(R.id.btn_threeidiotscoding);
                            mv_shop  =  findViewById(R.id.mv_shop);
                    }
                    public  void  onClick(View  v){
                            Intent  intent  =  new  Intent(Intent.ACTION_VIEW);
                            switch  (v.getId()){
                                    case  R.id.btn_threeidiotscoding:
                                            intent.setData(Uri.parse("http://192.168.0.6/mdp/"));
                                            startActivity(intent);
                                            break;


                                    case  R.id.mv_shop:
                                            intent.setData(Uri.parse("https://url.kr/3la52j"));
                                            startActivity(intent);
                            }
                    }
            }


            [  초기  페이지  ]
            <!DOCTYPE  html>
            <html  lang="ko">
            <head>
                <!--  Site  made  with  Mobirise  Website  Builder  v5.6.13,  https://mobirise.com  -->
                <meta  charset="UTF-8">
                <meta  http-equiv="X-UA-Compatible"  content="IE=edge">
                <meta  name="generator"  content="Mobirise  v5.6.13,  mobirise.com">
                <meta  name="twitter:card"  content="summary_large_image"/>
                <meta  name="twitter:image:src"  content="">
                <meta  property="og:image"  content="">
                <meta  name="twitter:title"  content="Home">
                <meta  name="viewport"  content="width=device-width,  initial-scale=1,  minimum-scale=1">
                <link  rel="shortcut  icon"  href="assets/images/logo5.png"  type="image/x-icon">
                <meta  name="description"  content="">
                <title>Home</title>
   327   328   329   330   331   332   333   334   335   336   337