Bladeren bron

Merge branch 'master' of http://git.choozmo.com:3000/choozmo/kw_tools into master

Your Name 3 jaren geleden
bovenliggende
commit
0ef1a04439
5 gewijzigde bestanden met toevoegingen van 867 en 161 verwijderingen
  1. BIN
      similar_web/Labinaagu.png
  2. 257 161
      similar_web/index.html
  3. 436 0
      similar_web/keywords.html
  4. 126 0
      similar_web/main.css
  5. 48 0
      similar_web/reset.css

BIN
similar_web/Labinaagu.png


+ 257 - 161
similar_web/index.html

@@ -1,32 +1,41 @@
-<html>
+<!DOCTYPE html>
+<html lang="en">
 <head>
-<!-- Font Awesome -->
-<link
-  href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"
-  rel="stylesheet"
-/>
-<!-- Google Fonts -->
-<link
-  href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap"
-  rel="stylesheet"
-/>
-<!-- MDB -->
-<link
-  href="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.css"
-  rel="stylesheet"
-/>
-<!-- MDB -->
-<script
-  type="text/javascript"
-  src="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.js"
-></script>    
-<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
-<script src="echarts.min.js"></script>
+  <meta charset="UTF-8">
+  <meta name="viewport" content="width=device-width, initial-scale=1.0">
+  <meta http-equiv="X-UA-Compatible" content="ie=edge">
+  <title>Googo Website Traffic</title>
+  <!-- Font Awesome -->
+  <link
+    href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"
+    rel="stylesheet"
+  />
+  <!-- Google Fonts -->
+  <link
+    href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap"
+    rel="stylesheet"
+  />
+  <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
+    integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
+  <!-- MDB -->
+  <link
+    href="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.css"
+    rel="stylesheet"
+  />
+  <link rel="stylesheet" href="https://unpkg.com/js-datepicker/dist/datepicker.min.css">
+  <link rel="stylesheet" type="text/css" href="reset.css">
+  <link rel="stylesheet" type="text/css" href="main.css">
+  <!-- MDB -->
+  <script
+    type="text/javascript"
+    src="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.js"
+  ></script>    
+  <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
+  <script src="echarts.min.js"></script>
 </head>
-<body>
-
+<body class="color__grey">
 <!-- Navbar -->
-<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
+  <nav class="navbar navbar-expand-lg navbar-light bg-white">
     <!-- Container wrapper -->
     <div class="container-fluid">
       <!-- Navbar brand -->
@@ -44,7 +53,7 @@
         <!-- Left links -->
         <ul class="navbar-nav me-auto d-flex flex-row mt-3 mt-lg-0">
           <li class="nav-item text-center mx-2 mx-lg-1">
-            <a class="nav-link active" aria-current="page" href="/">
+            <a class="nav-link active" aria-current="page" href="index.html">
               <div>
                 <i class="fas fa-home fa-lg mb-1"></i>
               </div>
@@ -55,14 +64,22 @@
             <a class="nav-link" href="http://news.google.com">
               <div>
                 <i class="fas fa-globe-americas fa-lg mb-1"></i>
-                <span class="badge rounded-pill badge-notification bg-success">11</span>
+                <!-- <span class="badge rounded-pill badge-notification bg-success">11</span> -->
               </div>
               News
             </a>
           </li>
+          <li class="nav-item text-center mx-2 mx-lg-1">
+            <a class="nav-link" href="keywords.html">
+              <div>
+                <i class="fab fa-korvue fa-lg mb-1"></i>
+                <!-- <span class="badge rounded-pill badge-notification bg-success">11</span> -->
+              </div>
+              Keywords
+            </a>
+          </li>
         </ul>
         <!-- Right links -->
-  
       </div>
       <!-- Collapsible wrapper -->
     </div>
@@ -70,71 +87,115 @@
   </nav>
   <!-- Navbar -->
 
-
-</br>
-
-<div class="container">
-  <div class="row">
-    <div class="col-1 col-lg-1"></div>
-
-    <div class="col-sm-11 col-lg-11">
-        <!-- Search form  -->
-
-        <form id="searchform" class="d-flex input-group w-auto" >
-          <input type="search" class="form-control" placeholder="Search" aria-label="Domain Name" id="search_query"/>
-          <button class="btn btn-primary" type="button" data-mdb-ripple-color="dark" onclick="check_form();">
-            Search
+  <div class="container">
+    <div class="row">
+      <!-- <div class="col-1 col-lg-1"></div> -->
+      <div class="col-12 col-12">
+          <!-- Search form  -->
+        <form id="searchform" class="d-flex input-group search__form">
+          <input type="search" class="form-control search__bar" placeholder="Search" aria-label="Domain Name" id="search_query"/>
+          <button class="btn btn-primary search__btn" type="button" data-mdb-ripple-color="dark" id="search__btn">
+              Search
           </button>
         </form>
-       
-
-
-        <div class="card text-center">
-          <div class="card-header" id="sitename">Website Traffic</div>
-          <div class="card-body">
-            <h5 class="card-title" id="sitetitle"></h5>
-            <p class="card-text" id="descriptions">
-            </p>
-<!--            <a href="#" class="btn btn-primary" id="globalrank2"></a> -->
-          </div>
-
-
-
-
-
-
-          <div class="row">
-            <div class="col-sm-4">
-              <div class="card">
-                <div class="card-body">
-                  <h5 class="card-title">Global Ranks</h5>
-                  <p class="card-text" >
-                  </p>
-                  <a href="#" class="btn btn-primary" id="globalrank"></a>
+          <h3 class="h3 text-center" id="sitename">Website Traffic</h3>
+            <div class="card card__grback mb-4">
+              <div class="card-body card__left">
+              <!-- 根據搜尋內容顯示網站標題及網站內容簡介 -->
+                <h5 class="card-title card__url" id="sitetitle"><i class="fas fa-chart-bar card__url__icon"></i>Example.com</h5>
+                <p class="card-text card__intro" id="descriptions">
+                  Lorem ipsum dolor sit amet consectetur adipisicing elit. Ut ipsa totam maxime pariatur iure 
+                  suscipit nihil possimus deserunt esse blanditiis. Quidem aliquid, voluptas quae tenetur quaerat 
+                  iure explicabo repellat ad.
+                </p>
+  <!--            <a href="#" class="btn btn-primary" id="globalrank2"></a> -->
+              </div>
+            </div>
+            <div class="date__input mb-3">
+              <label for="daterng">開始日期:</label><input type="text" name="daterng" id="daterng1">
+              <label for="daterng">結束日期:</label><input type="text" name="daterng" id="daterng2">
+              <button class='sub__date btn'>套用</button>
+            </div>
+            <div class="text-muted mb-2 border-bottom">RANKING</div>
+            <div class="row g-5 mb-3">
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">Global Ranks</h5>
+                    <p class="card-text" >
+                    </p>
+                    <span href="#" class="rank__mark"># <strong id="globalrank" class="rank_num">1000</strong></span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">Country Ranks</h5>
+                    <p class="card-text">
+                    </p>
+                    <span href="#" class="rank__mark"># <strong id="countryrank" class="rank_num">100</strong></span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2"><i class="fas fa-tags"></i>Category</h5>
+                    <p class="card-text card__rank__cat" id="category">
+                      Lorem
+                    </p>
+                  </div>
                 </div>
               </div>
             </div>
-            <div class="col-sm-4">
-              <div class="card">
-                <div class="card-body">
-                  <h5 class="card-title">Country Ranks</h5>
-                  <p class="card-text">
-                  </p>
-                  <a href="#" class="btn btn-primary" id="countryrank"></a>
+            <div class="text-muted mt-5 mb-2">Global Website Traffic Rankings</div>
+            <div class="row mb-4">
+              <div class="col-12 col-12">
+                  <!--
+                  <button type="button" class="btn btn-primary btn-block mb-4 ripple-surface">Place order</button>
+                  -->
+                <div class="card card__notHover">
+                  <div id="main" class="chart"></div>
                 </div>
               </div>
             </div>
-            <div class="col-sm-4">
-              <div class="card">
-                <div class="card-body">
-                  <h5 class="card-title">Category</h5>
-                  <p class="card-text" id="category">
-                  </p>
-<!--                  <a href="#" class="btn btn-primary" ></a>-->
-
+            <div class="text-muted mb-2 border-bottom">BENEFIT</div>
+            <div class="btn-group group__btn" role="group" aria-label="date-buttons">
+              <button class="btn__benefit active">搜尋流量</button>
+              <button class="btn__benefit">有搜尋流量的網頁數</button>
+            </div>
+            <div class="row g-5 mb-3">
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">搜尋流量</h5>
+                    <p class="card-text" >
+                    </p>
+                    <span href="#" class="rank__mark"><strong id="globalrank" class="rank_num">1000</strong></span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">有搜尋流量的網頁數</h5>
+                    <p class="card-text">
+                    </p>
+                    <span href="#" class="rank__mark"><strong id="countryrank" class="rank_num">100</strong></span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2"><i class="fas fa-tags"></i>轉換訂單數</h5>
+                    <span href="#" class="rank__mark"><strong id="countryrank" class="rank_num">100</strong></span>
+                  </div>
                 </div>
               </div>
             </div>
+<<<<<<< HEAD
 
           </div>
 
@@ -172,92 +233,127 @@
 
 
 
+=======
+            <div class="row mb-4">
+              <div class="col-12 col-12">
+                  <!--
+                  <button type="button" class="btn btn-primary btn-block mb-4 ripple-surface">Place order</button>
+                  -->
+                <div class="card card__notHover">
+                  <div id="main" class="chart"></div>
+                </div>
+              </div>
+            </div>
+            <div class="text-muted mb-2 border-bottom">SEO</div>
+            <div class="row mb-4">
+              <div class="col-12 col-12">
+                  <!--
+                  <button type="button" class="btn btn-primary btn-block mb-4 ripple-surface">Place order</button>
+                  -->
+                <div class="card card__notHover">
+                  <div id="bar" class="chart"></div>
+                </div>
+              </div>
+            </div>
+      </div>
+>>>>>>> 84eba5233aa481afde55c375a1d4f44475ce6e04
     </div>
   </div>
-
-
-
-</div>
-
-
-
-
-
+  <footer class="footer text-center p-4 bg-white">
+    <div class="text-muted"> © 2021 Copyright: Googo Website Traffic</div>
+  </footer>
+  <script
+  src="https://code.jquery.com/jquery-3.6.0.min.js"
+  integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4="
+  crossorigin="anonymous"></script>
+  <script src="https://unpkg.com/js-datepicker"></script>
 
 <script>
-
-var input = document.getElementById("search_query");
-
-input.addEventListener("keyup", function(event) {
-  // Number 13 is the "Enter" key on the keyboard
-  if (event.keyCode === 13) {
+  const input = document.getElementById("search_query");
+  const search__btn = document.getElementById("search__btn");
+  const btn__benefit = document.querySelectorAll(".btn__benefit");
+  const picker_str = datepicker('#daterng1', {
+    id: 1
+  });
+  const picker_end = datepicker('#daterng2', {
+    id: 1
+  });
+  $('.sub__date').click(function(e){
+    e.preventDefault();
+    console.log(picker_end.getRange());
+  });
+  search__btn.addEventListener("click", function(e) {
+    e.preventDefault();
     check_form();
-    event.preventDefault();
-//    document.getElementById("myBtn").click();
-  }
-});
-
-        var myChart = echarts.init(document.getElementById('main'));
-
-        var option;
-
-function check_form(){
-    var qry=document.getElementById('search_query').value;
-    axios.get('http://www.googo.org:8080/domain/'+qry)
-  .then((response) => {
-    var sitename = document.getElementById('sitename');
-    var sitetitle = document.getElementById('sitetitle');
-    var descriptions=document.getElementById('descriptions');
-    var globalrank=document.getElementById('globalrank');
-    var countryrank=document.getElementById('countryrank');    
-    var category=document.getElementById('category');    
-
-    console.log(response.data);
-//    alert(response.data.SiteName);
-//    var obj = JSON.parse(response.data);
-//    alert(obj);
-    sitename.innerHTML =response.data.SiteName;
-    descriptions.innerHTML=response.data.Description;
-    globalrank.innerHTML=response.data.GlobalRank.Rank;
-    sitetitle.innerHTML=response.data.Title;
-    countryrank.innerHTML=response.data.CountryRank.Rank;
-    category.innerHTML=response.data.Category;
- 
-    var key_ary=[];
-    var val_ary=[];
-    for (const [key, value] of Object.entries(response.data.EstimatedMonthlyVisits)) {
-      key_ary.push(key);
-      val_ary.push(value);
-}
-option = {
-    xAxis: {
-        type: 'category',
-        boundaryGap: false,
-        data: key_ary
-    },
-    yAxis: {
-        type: 'value'
-    },
-    series: [{
-        data: val_ary,
-        type: 'line',
-        areaStyle: {}
-    }]
-};
-
-        myChart.setOption(option);
-
-
-
-    //    sitename.innerHTML =response.data
-
-    console.log(response.status);
-    console.log(response.statusText);
-    console.log(response.headers);
-    console.log(response.config);
+  })
+  input.addEventListener("keyup", function(event) {
+    // Number 13 is the "Enter" key on the keyboard
+    if (event.keyCode === 13) {
+      check_form();
+      event.preventDefault();
+  //    document.getElementById("myBtn").click();
+    }
+  });
 
+  btn__benefit.forEach((item, i) => {
+    item.addEventListener("click", function(){
+      item.toggleClass('active');
+    })
   });
 
+  const myChart = echarts.init(document.getElementById('main'));
+  let option;
+
+  function check_form(){
+      const qry = document.getElementById('search_query').value;
+      axios.get('http://www.googo.org:8080/domain/' + qry)
+      .then((response) => {
+        const sitename = document.getElementById('sitename');
+        const sitetitle = document.getElementById('sitetitle');
+        const descriptions = document.getElementById('descriptions');
+        const globalrank = document.getElementById('globalrank');
+        const countryrank = document.getElementById('countryrank');    
+        const category = document.getElementById('category');    
+
+        console.log(response.data); 
+        //    alert(response.data.SiteName);
+        //    var obj = JSON.parse(response.data);
+        //    alert(obj);
+        itename.textContent =response.data.SiteName;
+        descriptions.textContent=response.data.Description;
+        globalrank.textContent=response.data.GlobalRank.Rank;
+        sitetitle.textContent=response.data.Title;
+        countryrank.textContent=response.data.CountryRank.Rank;
+        category.textContent=response.data.Category;
+    
+        const key_ary=[];
+        const val_ary=[];
+        for (const [key, value] of Object.entries(response.data.EstimatedMonthlyVisits)) {
+          key_ary.push(key);
+          val_ary.push(value);
+        }
+        option = {
+            xAxis: {
+                type: 'category',
+                boundaryGap: false,
+                data: key_ary
+            },
+            yAxis: {
+                type: 'value'
+            },
+            series: [{
+                data: val_ary,
+                type: 'line',
+                areaStyle: {}
+            }]
+        };
+            myChart.setOption(option);
+      //   sitename.innerHTML =response.data
+
+      // var bar = document.getElementById('bar');
+
+      // var barChart = echarts.init(bar);
+    });
   }
 </script>
 

+ 436 - 0
similar_web/keywords.html

@@ -0,0 +1,436 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+  <meta charset="UTF-8">
+  <meta name="viewport" content="width=device-width, initial-scale=1.0">
+  <meta http-equiv="X-UA-Compatible" content="ie=edge">
+  <title>Googo Website Traffic</title>
+  <!-- Font Awesome -->
+  <link
+    href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"
+    rel="stylesheet"
+  />
+  <!-- Google Fonts -->
+  <link
+    href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap"
+    rel="stylesheet"
+  />
+  <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
+    integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T" crossorigin="anonymous">
+  <!-- MDB -->
+  <link
+    href="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.css"
+    rel="stylesheet"
+  />
+  <link rel="stylesheet" href="https://unpkg.com/js-datepicker/dist/datepicker.min.css">
+  <link rel="stylesheet" type="text/css" href="reset.css">
+  <link rel="stylesheet" type="text/css" href="main.css">
+  <!-- MDB -->
+  <script
+    type="text/javascript"
+    src="https://cdnjs.cloudflare.com/ajax/libs/mdb-ui-kit/3.3.0/mdb.min.js"
+  ></script>    
+  <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
+  <script src="echarts.min.js"></script>
+</head>
+<body class="color__grey">
+<!-- Navbar -->
+  <nav class="navbar navbar-expand-lg navbar-light bg-white">
+    <!-- Container wrapper -->
+    <div class="container-fluid">
+      <!-- Navbar brand -->
+      <a class="navbar-brand" href="#">Googo Website Traffic</a>
+  
+      <!-- Toggle button -->
+      <button class="navbar-toggler" type="button" data-mdb-toggle="collapse"
+        data-mdb-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false"
+        aria-label="Toggle navigation">
+        <i class="fas fa-bars text-light"></i>
+      </button>
+  
+      <!-- Collapsible wrapper -->
+      <div class="collapse navbar-collapse" id="navbarSupportedContent">
+        <!-- Left links -->
+        <ul class="navbar-nav me-auto d-flex flex-row mt-3 mt-lg-0">
+          <li class="nav-item text-center mx-2 mx-lg-1">
+            <a class="nav-link active" aria-current="page" href="index.html">
+              <div>
+                <i class="fas fa-home fa-lg mb-1"></i>
+              </div>
+              Home
+            </a>
+          </li>
+          <li class="nav-item text-center mx-2 mx-lg-1">
+            <a class="nav-link" href="http://news.google.com">
+              <div>
+                <i class="fas fa-globe-americas fa-lg mb-1"></i>
+                <!-- <span class="badge rounded-pill badge-notification bg-success">11</span> -->
+              </div>
+              News
+            </a>
+          </li>
+          <li class="nav-item text-center mx-2 mx-lg-1">
+            <a class="nav-link" href="keywords.html">
+              <div>
+                <i class="fab fa-korvue fa-lg mb-1"></i>
+                <!-- <span class="badge rounded-pill badge-notification bg-success">11</span> -->
+              </div>
+              Keywords
+            </a>
+          </li>
+        </ul>
+        <!-- Right links -->
+      </div>
+      <!-- Collapsible wrapper -->
+    </div>
+    <!-- Container wrapper -->
+  </nav>
+  <!-- Navbar -->
+
+  <div class="container">
+    <div class="row">
+      <!-- <div class="col-1 col-lg-1"></div> -->
+      <div class="col-12 col-12">
+          <!-- Search form  -->
+        <form id="searchform" class="d-flex input-group search__form align-item-center keyword_add" >
+          <input type="search" class="form-control search__bar" placeholder="新增追蹤關鍵字" aria-label="Domain Name" id="following_keys"/>
+          <button class="btn btn-primary search__btn" type="button" data-mdb-ripple-color="dark" id="search__btn">
+              加入
+          </button>
+        </form>
+        <div class="keyword_total mx-auto mb-4">目前有 <strong>N</strong> 個追蹤關鍵字</div>
+        <div class="date__input mb-3">
+          <label for="daterng">開始日期:</label><input type="text" name="daterng" id="daterng1">
+          <label for="daterng">結束日期:</label><input type="text" name="daterng" id="daterng2">
+          <button class='sub__date btn'>套用</button>
+        </div>
+            <div class="text-muted mb-2 border-bottom">追蹤關鍵字排名</div>
+            <div class="row g-5 mb-3">
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">排名前一頁關鍵字</h5>
+                    <p class="card-text" >
+                    </p>
+                    <span href="#" class="rank__mark"><strong id="globalrank" class="rank_num">1000</strong>個</span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2">排名前三頁關鍵字</h5>
+                    <p class="card-text">
+                    </p>
+                    <span href="#" class="rank__mark"><strong id="countryrank" class="rank_num">100</strong>個</span>
+                  </div>
+                </div>
+              </div>
+              <div class="col-sm-4">
+                <div class="card p-3">
+                  <div class="card-body text-center">
+                    <h5 class="card-title card__rank__title mb-2"><i class="fas fa-tags"></i>排名前十頁關鍵字</h5>
+                    <p class="card-text card__rank__cat" id="category">
+                    </p>
+                    <span href="#" class="rank__mark"><strong id="countryrank" class="rank_num">100</strong>個</span>
+                  </div>
+                </div>
+              </div>
+            </div>
+            <div class="text-muted mb-2">追蹤關鍵字列表</div>
+            <table id="dtBasicExample" class="table" cellspacing="0" width="100%">
+              <thead>
+                <tr>
+                  <th class="th-sm">關鍵字
+                  </th>
+                  <th class="th-sm">排名
+                  </th>
+                  <th class="th-sm">搜尋量
+                  </th>
+                  <th class="th-sm">曝光數
+                  </th>
+                  <th class="th-sm">CTR
+                  </th>
+                  <th class="th-sm">頁面搜尋流量
+                  </th>
+                  <th></th>
+                </tr>
+              </thead>
+              <tbody>
+                <tr>
+                  <td>Tiger Nixon</td>
+                  <td>System Architect</td>
+                  <td>Edinburgh</td>
+                  <td>61</td>
+                  <td>2011/04/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Garrett Winters</td>
+                  <td>Accountant</td>
+                  <td>Tokyo</td>
+                  <td>63</td>
+                  <td>2011/07/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Ashton Cox</td>
+                  <td>Junior Technical Author</td>
+                  <td>San Francisco</td>
+                  <td>66</td>
+                  <td>2009/01/12</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+              </tbody>
+            </table>
+            <div class="text-muted mb-2">搜尋關鍵字現況(連google search console 資料)</div>
+            <table id="dtBasicExample" class="table" cellspacing="0" width="100%">
+              <thead>
+                <tr>
+                  <th class="th-sm">關鍵字
+                  </th>
+                  <th class="th-sm">排名
+                  </th>
+                  <th class="th-sm">搜尋量
+                  </th>
+                  <th class="th-sm">曝光數
+                  </th>
+                  <th class="th-sm">CTR
+                  </th>
+                  <th class="th-sm">頁面搜尋流量
+                  </th>
+                  <th></th>
+                </tr>
+              </thead>
+              <tbody>
+                <tr>
+                  <td>Tiger Nixon</td>
+                  <td>System Architect</td>
+                  <td>Edinburgh</td>
+                  <td>61</td>
+                  <td>2011/04/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Garrett Winters</td>
+                  <td>Accountant</td>
+                  <td>Tokyo</td>
+                  <td>63</td>
+                  <td>2011/07/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Ashton Cox</td>
+                  <td>Junior Technical Author</td>
+                  <td>San Francisco</td>
+                  <td>66</td>
+                  <td>2009/01/12</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+              </tbody>
+            </table>
+            <div class="text-muted mb-2">關鍵字建議</div>
+            <table id="dtBasicExample" class="table" cellspacing="0" width="100%">
+              <thead>
+                <tr>
+                  <th class="th-sm">關鍵字
+                  </th>
+                  <th class="th-sm">排名
+                  </th>
+                  <th class="th-sm">搜尋量
+                  </th>
+                  <th class="th-sm">曝光數
+                  </th>
+                  <th class="th-sm">CTR
+                  </th>
+                  <th class="th-sm">頁面搜尋流量
+                  </th>
+                  <th></th>
+                </tr>
+              </thead>
+              <tbody>
+                <tr>
+                  <td>Tiger Nixon</td>
+                  <td>System Architect</td>
+                  <td>Edinburgh</td>
+                  <td>61</td>
+                  <td>2011/04/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Garrett Winters</td>
+                  <td>Accountant</td>
+                  <td>Tokyo</td>
+                  <td>63</td>
+                  <td>2011/07/25</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+                <tr>
+                  <td>Ashton Cox</td>
+                  <td>Junior Technical Author</td>
+                  <td>San Francisco</td>
+                  <td>66</td>
+                  <td>2009/01/12</td>
+                  <td>989</td>
+                  <td><i class="fas fa-trash-alt"></i></td>
+                </tr>
+              </tbody>
+            </table>
+      </div>
+    </div>
+  </div>
+  <footer class="footer text-center p-4 bg-white">
+    <div class="text-muted"> © 2021 Copyright: Googo Website Traffic</div>
+  </footer>
+  <script
+  src="https://code.jquery.com/jquery-3.6.0.min.js"
+  integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4="
+  crossorigin="anonymous"></script>
+<script src="https://unpkg.com/js-datepicker"></script>
+
+<script>
+const input = document.getElementById("search_query");
+const search__btn = document.getElementById("search__btn");
+const picker_str = datepicker('#daterng1', {
+  id: 1
+});
+const picker_end = datepicker('#daterng2', {
+  id: 1
+});
+$('.sub__date').click(function(e){
+  e.preventDefault();
+  console.log(picker_end.getRange());
+});
+search__btn.addEventListener("click", function(e) {
+  e.preventDefault();
+  check_form();
+})
+input.addEventListener("keyup", function(event) {
+  // Number 13 is the "Enter" key on the keyboard
+  if (event.keyCode === 13) {
+    check_form();
+    event.preventDefault();
+//    document.getElementById("myBtn").click();
+  }
+});
+$(document).ready(function () {
+$('#dtBasicExample').DataTable();
+$('.dataTables_length').addClass('bs-select');
+});
+
+const myChart = echarts.init(document.getElementById('main'));
+let option;
+
+function check_form(){
+    const qry = document.getElementById('search_query').value;
+    axios.get('http://www.googo.org:8080/domain/' + qry)
+    .then((response) => {
+      const sitename = document.getElementById('sitename');
+      const sitetitle = document.getElementById('sitetitle');
+      const descriptions = document.getElementById('descriptions');
+      const globalrank = document.getElementById('globalrank');
+      const countryrank = document.getElementById('countryrank');    
+      const category = document.getElementById('category');    
+
+      console.log(response.data); 
+      //    alert(response.data.SiteName);
+      //    var obj = JSON.parse(response.data);
+      //    alert(obj);
+      itename.textContent =response.data.SiteName;
+      descriptions.textContent=response.data.Description;
+      globalrank.textContent=response.data.GlobalRank.Rank;
+      sitetitle.textContent=response.data.Title;
+      countryrank.textContent=response.data.CountryRank.Rank;
+      category.textContent=response.data.Category;
+  
+      const key_ary=[];
+      const val_ary=[];
+      for (const [key, value] of Object.entries(response.data.EstimatedMonthlyVisits)) {
+        key_ary.push(key);
+        val_ary.push(value);
+      }
+      option = {
+          xAxis: {
+              type: 'category',
+              boundaryGap: false,
+              data: key_ary
+          },
+          yAxis: {
+              type: 'value'
+          },
+          series: [{
+              data: val_ary,
+              type: 'line',
+              areaStyle: {}
+          }]
+      };
+          myChart.setOption(option);
+      //    sitename.innerHTML =response.data
+      var bar = document.getElementById('bar');
+
+var barChart = echarts.init(bar);
+let traffics;
+
+traffics = {
+    title: {
+        text: '世界人口总量',
+        subtext: '数据来自网络'
+    },
+    tooltip: {
+        trigger: 'axis',
+        axisPointer: {
+            type: 'shadow'
+        }
+    },
+    legend: {
+        data: ['2011年', '2012年']
+    },
+    grid: {
+        left: '3%',
+        right: '4%',
+        bottom: '3%',
+        containLabel: true
+    },
+    xAxis: {
+        type: 'value',
+        boundaryGap: [0, 0.01]
+    },
+    yAxis: {
+        type: 'category',
+        data: ['巴西', '印尼', '美国', '印度', '中国', '世界人口(万)']
+    },
+    series: [
+        {
+            name: '2011年',
+            type: 'bar',
+            data: [18203, 23489, 29034, 104970, 131744, 630230]
+        },
+        {
+            name: '2012年',
+            type: 'bar',
+            data: [19325, 23438, 31000, 121594, 134141, 681807]
+        }
+    ]
+};
+
+  traffics && barChart.setOption(traffics);
+      console.log(response.status);
+      console.log(response.statusText);
+      console.log(response.headers);
+      console.log(response.config);
+    });
+  }
+</script>
+
+</body>
+
+    
+</html>

+ 126 - 0
similar_web/main.css

@@ -0,0 +1,126 @@
+@import url('https://fonts.googleapis.com/css2?family=Work+Sans:wght@400;500;600&display=swap');
+body {
+    font-family: 'Work Sans', sans-serif;
+}
+/* body background */
+.color__grey {
+    background-color: #f5f5f5;
+}
+/* search bar */
+.search__form {
+    width: 40rem;
+    margin: 3rem auto;
+}
+.search__btn {
+    padding: 8px 24px;
+}
+.search__form .search__bar:focus {
+    box-shadow: 1px 1px 3px 1px #1266f1;
+}
+
+.h3 {
+    font-size: 2rem;
+}
+
+/* card */
+.card{
+    transition: all .3s;
+}
+.card:hover {
+    transform: scale(1.05);
+}
+.card.card__notHover {
+    transform: scale(1);
+}
+.card-title {
+    font-size: 1.3rem;
+}
+/* top card */
+.card__grback {
+    background-image: linear-gradient(105deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.9) 65%, #1266f1 65%, #1266f1 100%);
+}
+.card__left {
+    width: 60%;
+}
+.card__url {
+    font-size: 1.8rem;
+    margin-bottom: 1.5rem;
+}
+.card__url__icon {
+    display: inline-block;
+    margin-right: 1rem;
+    font-size: 1.4rem;
+}
+.card__intro {
+    font-size: .9rem;
+    line-height: 1.5rem;
+}
+/* rank card */
+.card__rank__title {
+    font-weight: 500;
+}
+.card__rank__title i {
+    display: inline-block;
+    margin-right: .5rem;
+    font-size: 1.2rem;
+}
+.sub__date {
+    padding: .3rem .75rem;
+}
+.rank__mark {
+    font-size: 1.4rem;
+    line-height: 1.4rem;
+}
+.rank_num {
+    font-size: 2rem;
+}
+/* chart */
+.chart {
+    width: 600px;
+    height:220px;
+    margin:1.5rem auto;
+}
+
+.add__words {
+    line-height: 1.3rem;
+}
+
+.keyword_total {
+    font-weight: 500;
+    text-align: center;
+}
+.keyword_total > strong {
+    font-size: 1.6rem;
+}
+.keyword_add {
+    margin: 1rem auto;
+}
+
+.group__btn {
+    border-radius: 10px;
+    margin-bottom: 1rem;
+}
+.btn-group .btn__benefit {
+    border: 1px solid grey;
+    background-color: white;
+    padding: .5rem;
+    width: 8rem;
+    font-size: .9rem;
+    transition: all .4s;
+}
+  
+  .btn-group .btn__benefit:nth-of-type(1) {
+    border-radius: 5px 0  0 5px;
+  }
+  .btn-group .btn__benefit:nth-of-type(2) {
+    border-radius: 0 5px 5px 0;
+  }
+  .btn-group .btn__benefit:hover {
+    background-color: grey;
+    color: white;
+  }
+  
+  .btn-group .btn__benefit.active {
+    background-color: grey;
+    color: white;
+  }

+ 48 - 0
similar_web/reset.css

@@ -0,0 +1,48 @@
+/* http://meyerweb.com/eric/tools/css/reset/ 
+   v2.0 | 20110126
+   License: none (public domain)
+*/
+
+html, body, div, span, applet, object, iframe,
+h1, h2, h3, h4, h5, h6, p, blockquote, pre,
+a, abbr, acronym, address, big, cite, code,
+del, dfn, em, img, ins, kbd, q, s, samp,
+small, strike, strong, sub, sup, tt, var,
+b, u, i, center,
+dl, dt, dd, ol, ul, li,
+fieldset, form, label, legend,
+table, caption, tbody, tfoot, thead, tr, th, td,
+article, aside, canvas, details, embed, 
+figure, figcaption, footer, header, hgroup, 
+menu, nav, output, ruby, section, summary,
+time, mark, audio, video {
+	margin: 0;
+	padding: 0;
+	border: 0;
+	font-size: 100%;
+	font: inherit;
+	vertical-align: baseline;
+}
+/* HTML5 display-role reset for older browsers */
+article, aside, details, figcaption, figure, 
+footer, header, hgroup, menu, nav, section {
+	display: block;
+}
+body {
+	line-height: 1;
+}
+ol, ul {
+	list-style: none;
+}
+blockquote, q {
+	quotes: none;
+}
+blockquote:before, blockquote:after,
+q:before, q:after {
+	content: '';
+	content: none;
+}
+table {
+	border-collapse: collapse;
+	border-spacing: 0;
+}