瀏覽代碼

頁面問題修正

jeter20131220 3 年之前
父節點
當前提交
9a28bd63e4
共有 7 個文件被更改,包括 143 次插入73 次删除
  1. 60 55
      desktop11/index.html
  2. 11 4
      desktop11/style.css
  3. 0 0
      desktop11/style.css.map
  4. 9 1
      desktop11/style.scss
  5. 54 4
      mobile/index.html
  6. 7 7
      mobile/style.css
  7. 2 2
      mobile/style.scss

+ 60 - 55
desktop11/index.html

@@ -20,7 +20,8 @@
     <meta property="og:locale" content="zh_TW">
     <title>全室裝修</title>
 
-
+    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.css">
+    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js">
     <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/css/bootstrap.min.css" rel="stylesheet"
         integrity="sha384-+0n0xVW2eSR5OomGNYDnhzAbDsOXxcvSN1TPprVMTNDbiYZCxYbOOl7+AMvyTG2x" crossorigin="anonymous">
     <link rel="stylesheet" type="text/css" href="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.css" />
@@ -30,47 +31,47 @@
 </head>
 
 <body id="top">
-<script>
-function statusChangeCallback(response) {  // Called with the results from FB.getLoginStatus().
-    if (response.status === 'connected') {  // 已登入
-        testAPI();  
-    }
-}
-
-function checkLoginState() {                 // Called when a person is finished with the Login Button.
-    FB.getLoginStatus(function(response) {   // See the onlogin handler
-        statusChangeCallback(response);
-    });
-}
-
-window.fbAsyncInit = function() {
-    FB.init({
-        appId      : '1388696554848391',
-        cookie     : true,            // Enable cookies to allow the server to access the session.
-        xfbml      : true,            // Parse social plugins on this webpage.
-        version    : 'v11.0'          // Use this Graph API version for this call.
-    });
-
-    FB.getLoginStatus(function(response) {   // Called after the JS SDK has been initialized.
-        statusChangeCallback(response);      // Returns the login status.
-    });
-};
-
-function testAPI() {
-    FB.api('/me/?fields=id,name,email', function(response) {
-        console.log('FB API回傳資料: ' + JSON.stringify(response));
-
-        if (response.id) {           
-            // 設定欄位預設值
-            document.getElementById("email").value = response.email;
-            document.getElementById("name").value = response.name;
-
-            // 隱藏FB登入按鈕
-            document.getElementById("fb_login").style.display = 'none';
+    <script>
+        function statusChangeCallback(response) {  // Called with the results from FB.getLoginStatus().
+            if (response.status === 'connected') {  // 已登入
+                testAPI();
+            }
+        }
+
+        function checkLoginState() {                 // Called when a person is finished with the Login Button.
+            FB.getLoginStatus(function (response) {   // See the onlogin handler
+                statusChangeCallback(response);
+            });
         }
-    });
-};
-</script>
+
+        window.fbAsyncInit = function () {
+            FB.init({
+                appId: '1388696554848391',
+                cookie: true,            // Enable cookies to allow the server to access the session.
+                xfbml: true,            // Parse social plugins on this webpage.
+                version: 'v11.0'          // Use this Graph API version for this call.
+            });
+
+            FB.getLoginStatus(function (response) {   // Called after the JS SDK has been initialized.
+                statusChangeCallback(response);      // Returns the login status.
+            });
+        };
+
+        function testAPI() {
+            FB.api('/me/?fields=id,name,email', function (response) {
+                console.log('FB API回傳資料: ' + JSON.stringify(response));
+
+                if (response.id) {
+                    // 設定欄位預設值
+                    document.getElementById("email").value = response.email;
+                    document.getElementById("name").value = response.name;
+
+                    // 隱藏FB登入按鈕
+                    document.getElementById("fb_login").style.display = 'none';
+                }
+            });
+        };
+    </script>
 
     <div class="container-fluid" style="padding:0;margin:0 ">
         <div class="banner container-fluid" style="padding:0; margin:0 ">
@@ -248,37 +249,43 @@ function testAPI() {
                 <h1 class="title">客戶真實見證</h1>
                 <div id="feedback-box">
                     <div class="box">
-                        <a href="https://hhh.com.tw/video-post.php?id=2905"><img src="./img/feedback-img/feedback01.webp" alt=""></a>
+                        <a href="https://hhh.com.tw/video-post.php?id=2905"><img
+                                src="./img/feedback-img/feedback01.webp" alt=""></a>
                         <p>嚮往人文接觸處的溫度-文響</p>
                         <a href="https://hhh.com.tw/video-post.php?id=2905"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
                     </div>
                     <div class="box">
-                        <a href="https://hhh.com.tw/video-post.php?id=3782"><img src="./img/feedback-img/feedback02.webp" alt=""></a>
+                        <a href="https://hhh.com.tw/video-post.php?id=3782"><img
+                                src="./img/feedback-img/feedback02.webp" alt=""></a>
                         <p>緞帶般曲線 譜出家的律動與甜蜜</p>
                         <a href="https://hhh.com.tw/video-post.php?id=3782"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
                     </div>
                     <div class="box">
-                        <a href="https://hhh.com.tw/video-post.php?id=3549"><img src="./img/feedback-img/feedback03.webp" alt=""></a>
+                        <a href="https://hhh.com.tw/video-post.php?id=3549"><img
+                                src="./img/feedback-img/feedback03.webp" alt=""></a>
                         <p>系統設計的變革 前衛科技宅</p>
                         <a href="https://hhh.com.tw/video-post.php?id=3549"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
                     </div>
                     <div class="box">
-                        <a href="https://hhh.com.tw/video-post.php?id=2985"><img src="./img/feedback-img/feedback0411.webp" alt=""></a>
+                        <a href="https://hhh.com.tw/video-post.php?id=2985"><img
+                                src="./img/feedback-img/feedback0411.webp" alt=""></a>
                         <p>用系統設計 實現歐洲皇室城堡夢</p>
                         <a href="https://hhh.com.tw/video-post.php?id=2985"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
                     </div>
                     <div class="box">
-                       <a href="https://hhh.com.tw/video-post.php?id=2122"><img src="./img/feedback-img/feedback05.webp" alt=""></a> 
+                        <a href="https://hhh.com.tw/video-post.php?id=2122"><img
+                                src="./img/feedback-img/feedback05.webp" alt=""></a>
                         <p>不良格局變身 3米6日光鄉村宅</p>
                         <a href="https://hhh.com.tw/video-post.php?id=2122"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
                     </div>
                     <div class="box">
-                        <a href="https://hhh.com.tw/video-post.php?id=3847"><img src="./img/feedback-img/feedback06.webp" alt=""></a>
+                        <a href="https://hhh.com.tw/video-post.php?id=3847"><img
+                                src="./img/feedback-img/feedback06.webp" alt=""></a>
                         <p>雙拼豪宅古典、日式一次擁有</p>
                         <a href="https://hhh.com.tw/video-post.php?id=3847"><img class="play"
                                 style="width: 3vw;height: 3vw  " src="./img/play (1).png" alt=""></a>
@@ -401,20 +408,18 @@ function testAPI() {
                                 <option class="option">工業風</option>
                                 <option class="option">異國風</option>
                             </select>
-                            <input name="prefer_date" type="date" id="date" value="預選裝修日期" placeholder="預選裝修日期" required>
+                            <input name="prefer_date" type="date" id="date" value="預選裝修日期" placeholder="預選裝修日期"
+                                required>
                         </div>
                         <hr>
                         <div id="form-right">
-                            <!-- <div id="facebook" onclick='callFB()'>
-                                <img src="./img/logo/facebook.webp" alt="">
-                                使用FB填入信箱與姓名
-                            </div> -->
-                            
+
                             <div id="fb_login">
-                                <fb:login-button scope="public_profile,email" onlogin="checkLoginState();">使用FB填入信箱與姓名</fb:login-button>
+                                <fb:login-button id="fb-button" scope="public_profile,email" onlogin="checkLoginState();">使用FB填入信箱與姓名
+                                </fb:login-button>
                                 <div id="status"></div>
                             </div>
-                            
+
                             <input type="text" name="email" id="email" placeholder="請輸入信箱" required>
                             <input type="text" name="name" id="name" placeholder="請輸入姓名" required>
                             <input type="text" name="phone" id="phone" placeholder="請輸入電話" required>

+ 11 - 4
desktop11/style.css

@@ -585,7 +585,14 @@ body .arrow {
   margin-left: 5vw;
 }
 
-#contact-us #contact-form #form-right #facebook {
+#contact-us #contact-form #form-right #fb_login #fb-button {
+  font-size: 16px;
+  width: 29vw;
+  height: 50px;
+  padding: 30px;
+}
+
+#contact-us #contact-form #form-right #111 {
   margin-top: 12px;
   width: 29vw;
   height: 50px;
@@ -599,7 +606,7 @@ body .arrow {
   position: relative;
 }
 
-#contact-us #contact-form #form-right #facebook img {
+#contact-us #contact-form #form-right #111 img {
   position: absolute;
   left: 50px;
   top: 7px;
@@ -607,12 +614,12 @@ body .arrow {
   height: 32px;
 }
 
-#contact-us #contact-form #form-right #facebook:hover {
+#contact-us #contact-form #form-right #111:hover {
   background-color: #2a4f91;
   color: #fff;
 }
 
-#contact-us #contact-form #form-right #facebook:hover img {
+#contact-us #contact-form #form-right #111:hover img {
   -webkit-filter: invert(100%) sepia(100%) saturate(19%) hue-rotate(334deg) brightness(106%) contrast(106%);
           filter: invert(100%) sepia(100%) saturate(19%) hue-rotate(334deg) brightness(106%) contrast(106%);
 }

文件差異過大導致無法顯示
+ 0 - 0
desktop11/style.css.map


+ 9 - 1
desktop11/style.scss

@@ -510,8 +510,16 @@ body {
         #form-right {
             width: 29vw;
             margin-left: 5vw;
+            #fb_login{
+                #fb-button{
+                    font-size: 16px;
+                    width: 29vw;
+                    height: 50px;
+                    padding: 30px;
+                }
+            }
 
-            #facebook {
+            #111 {
                 margin-top: 12px;
                 width: 29vw;
                 height: 50px;

+ 54 - 4
mobile/index.html

@@ -21,6 +21,12 @@
     <title>全室裝修</title>
 
 
+    
+
+
+
+<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.css">
+    
     <!-- Slick CDN -->
     <link rel="stylesheet" type="text/css" href="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick.css" />
     <link rel="stylesheet" type="text/css" href="//cdn.jsdelivr.net/npm/slick-carousel@1.8.1/slick/slick-theme.css" />
@@ -35,7 +41,48 @@
     <link rel="shortcut icon" href="./img/favicon.ico" type="image/x-icon">
 </head>
 
-<body>
+<body id="top">
+    <script>
+        function statusChangeCallback(response) {  // Called with the results from FB.getLoginStatus().
+            if (response.status === 'connected') {  // 已登入
+                testAPI();
+            }
+        }
+
+        function checkLoginState() {                 // Called when a person is finished with the Login Button.
+            FB.getLoginStatus(function (response) {   // See the onlogin handler
+                statusChangeCallback(response);
+            });
+        }
+
+        window.fbAsyncInit = function () {
+            FB.init({
+                appId: '1388696554848391',
+                cookie: true,            // Enable cookies to allow the server to access the session.
+                xfbml: true,            // Parse social plugins on this webpage.
+                version: 'v11.0'          // Use this Graph API version for this call.
+            });
+
+            FB.getLoginStatus(function (response) {   // Called after the JS SDK has been initialized.
+                statusChangeCallback(response);      // Returns the login status.
+            });
+        };
+
+        function testAPI() {
+            FB.api('/me/?fields=id,name,email', function (response) {
+                console.log('FB API回傳資料: ' + JSON.stringify(response));
+
+                if (response.id) {
+                    // 設定欄位預設值
+                    document.getElementById("email").value = response.email;
+                    document.getElementById("name").value = response.name;
+
+                    // 隱藏FB登入按鈕
+                    document.getElementById("fb_login").style.display = 'none';
+                }
+            });
+        };
+    </script>
     <nav class="navigation">
         <div class="logo">
             <a href="https://hhh.com.tw/"><img src="./img/logo/logomain-3.webp" alt=""></a>
@@ -368,9 +415,9 @@
                     <option class="option" value="type">異國風</option>
                 </select>
                 <input name="prefer_date" type="date" id="date"  placeholder="預選裝修日期" required>
-                <div id="facebook">
-                    <img src="./img/process/facebook.webp" alt="">
-                    <p>使用FB填入信箱與姓名 </p>
+                <div id="fb_login">
+                    <fb:login-button scope="public_profile,email" onlogin="checkLoginState();">使用FB填入信箱與姓名</fb:login-button>
+                    <div id="status"></div>
                 </div>
                 <input type="text" name="email" id="email" placeholder="請輸入信箱" required>
                 <input type="text" name="name" id="name" placeholder="請輸入姓名" required>
@@ -395,6 +442,9 @@
         <a href="https://hhh.com.tw/about/">|關於本站|</a>
     </div>
 
+
+<script src="https://cdnjs.cloudflare.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js"></script>
+    <script async defer crossorigin="anonymous" src="https://connect.facebook.net/en_US/sdk.js"></script>
     <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js"
         integrity="sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p"
         crossorigin="anonymous"></script>

+ 7 - 7
mobile/style.css

@@ -678,7 +678,7 @@ body .btn-main:hover {
   margin: 0 auto;
 }
 
-#contact-us #contact-form #facebook {
+#contact-us #contact-form #fb_login {
   margin: 15px auto;
   width: 85vw;
   height: 60px;
@@ -690,25 +690,25 @@ body .btn-main:hover {
   position: relative;
 }
 
-#contact-us #contact-form #facebook p {
+#contact-us #contact-form #fb_login p {
   position: absolute;
   right: 30px;
   font-weight: normal;
 }
 
 @media screen and (max-width: 1024px) {
-  #contact-us #contact-form #facebook p {
+  #contact-us #contact-form #fb_login p {
     top: 10px;
   }
 }
 
 @media screen and (max-width: 767px) {
-  #contact-us #contact-form #facebook p {
+  #contact-us #contact-form #fb_login p {
     top: 15px;
   }
 }
 
-#contact-us #contact-form #facebook img {
+#contact-us #contact-form #fb_login img {
   position: absolute;
   left: 30px;
   top: 15px;
@@ -716,12 +716,12 @@ body .btn-main:hover {
   height: 32px;
 }
 
-#contact-us #contact-form #facebook:hover {
+#contact-us #contact-form #fb_login:hover {
   background-color: #2a4f91;
   color: #fff;
 }
 
-#contact-us #contact-form #facebook:hover img {
+#contact-us #contact-form #fb_login:hover img {
   -webkit-filter: invert(100%) sepia(100%) saturate(19%) hue-rotate(334deg) brightness(106%) contrast(106%);
           filter: invert(100%) sepia(100%) saturate(19%) hue-rotate(334deg) brightness(106%) contrast(106%);
 }

+ 2 - 2
mobile/style.scss

@@ -581,7 +581,7 @@ body {
             display: block;
             margin: 0 auto;
         }
-        #facebook {
+        #fb_login {
             margin: 15px auto;
             width: 85vw;
             height: 60px;
@@ -719,7 +719,7 @@ body {
             color: #65584c;
             font-size: 16px;
             margin-top: 20px;
-            
+
         }
 
         .menu-text {

部分文件因文件數量過多而無法顯示