<!DOCTYPE html> <html lang="zh"> <head> <meta charset="UTF-8" /> <title>Favicon Hash 对比结果</title> <!-- DataTables CSS --> <link rel="stylesheet" href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" /> <style> /* 省略样式,跟你原来的一样,保持不变 */ body { margin: 0; padding: 40px 20px; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; background: #f0f2f5; color: #333; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } h2 { text-align: center; font-weight: 700; font-size: 2rem; margin-bottom: 0.3em; color: #222; } p.description { text-align: center; color: #666; font-size: 1rem; margin-bottom: 2em; user-select: none; } p.description strong { color: #0078d4; } .table-container { max-width: 980px; margin: 0 auto; background: #fff; border-radius: 12px; box-shadow: 0 4px 8px rgb(0 0 0 / 0.1), 0 2px 6px rgb(0 0 0 / 0.06); padding: 25px 30px; } table.dataTable thead th { background-color: #0078d4; color: white; font-weight: 600; font-size: 14px; padding: 14px 18px; } table.dataTable tbody tr { transition: background-color 0.15s ease; cursor: default; } table.dataTable tbody tr:hover { background-color: #e6f2ff; } table.dataTable tbody td { padding: 14px 18px; font-size: 14px; word-break: break-word; } .favicon { width: 20px; height: 20px; margin-right: 8px; vertical-align: middle; border-radius: 4px; border: 1px solid #ddd; box-shadow: 0 1px 3px rgb(0 0 0 / 0.1); } a { color: #0078d4; text-decoration: none; transition: color 0.2s ease; } a:hover { text-decoration: underline; color: #005a9e; } div.dataTables_wrapper div.dataTables_filter input { border-radius: 20px; border: 1.5px solid #0078d4; padding: 6px 15px; font-size: 14px; width: 240px; transition: all 0.3s ease; } div.dataTables_wrapper div.dataTables_filter input:focus { outline: none; box-shadow: 0 0 8px #0078d4aa; border-color: #005a9e; } .dataTables_paginate .paginate_button { background: #0078d4; color: white !important; border-radius: 4px; border: none; padding: 5px 12px; margin-left: 4px; cursor: pointer; transition: background-color 0.3s ease; } .dataTables_paginate .paginate_button.current, .dataTables_paginate .paginate_button:hover { background: #005a9e !important; color: white !important; } p.no-results { text-align: center; font-weight: 600; font-size: 1.1rem; color: #888; margin-top: 40px; user-select: none; } </style> </head> <body> <h2>以下是与指定 Hash 不同的 Favicon 链接</h2> <p class="description">排除的 Hash 值:<strong>{{ hashes }}</strong></p> <div class="table-container"> {% if results %} <table id="hashTable" class="display" style="width:100%"> <thead> <tr> <th>URL</th> <th>Favicon Hash</th> <th>Favicon URL</th> </tr> </thead> <tbody> {% for row in results %} <tr> <td>{{ row.URL }}</td> <td>{{ row['Favicon Hash'] }}</td> <td> <img class="favicon" src="{{ row['Favicon URL'] }}" onerror="this.style.display='none'"> <a href="{{ row['Favicon URL'] }}" target="_blank" rel="noopener noreferrer">{{ row['Favicon URL'] }}</a> </td> </tr> {% endfor %} </tbody> </table> {% else %} <p class="no-results"><strong>没有找到不同的记录。</strong></p> {% endif %} </div> <!-- jQuery --> <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script> <!-- DataTables JS --> <script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> <script> $(document).ready(function() { $('#hashTable').DataTable({ language: { lengthMenu: "每页显示 _MENU_ 条记录", zeroRecords: "没有找到匹配的记录", info: "显示第 _START_ 到 _END_ 条记录,共 _TOTAL_ 条", infoEmpty: "没有记录", infoFiltered: "(从 _MAX_ 条记录中过滤)", search: "搜索:", paginate: { first: "首页", last: "末页", next: "下一页", previous: "上一页" } }, pageLength: 10, lengthMenu: [5, 10, 20, 50], order: [] }); }); </script> </body> </html>sstyle.css
<!DOCTYPE html> <html lang="zh"> <head> <meta charset="UTF-8" /> <title>Favicon Hash 对比结果</title> <!-- DataTables CSS --> <link rel="stylesheet" href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css" /> <style> /* 省略样式,跟你原来的一样,保持不变 */ body { margin: 0; padding: 40px 20px; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; background: #f0f2f5; color: #333; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } h2 { text-align: center; font-weight: 700; font-size: 2rem; margin-bottom: 0.3em; color: #222; } p.description { text-align: center; color: #666; font-size: 1rem; margin-bottom: 2em; user-select: none; } p.description strong { color: #0078d4; } .table-container { max-width: 980px; margin: 0 auto; background: #fff; border-radius: 12px; box-shadow: 0 4px 8px rgb(0 0 0 / 0.1), 0 2px 6px rgb(0 0 0 / 0.06); padding: 25px 30px; } table.dataTable thead th { background-color: #0078d4; color: white; font-weight: 600; font-size: 14px; padding: 14px 18px; } table.dataTable tbody tr { transition: background-color 0.15s ease; cursor: default; } table.dataTable tbody tr:hover { background-color: #e6f2ff; } table.dataTable tbody td { padding: 14px 18px; font-size: 14px; word-break: break-word; } .favicon { width: 20px; height: 20px; margin-right: 8px; vertical-align: middle; border-radius: 4px; border: 1px solid #ddd; box-shadow: 0 1px 3px rgb(0 0 0 / 0.1); } a { color: #0078d4; text-decoration: none; transition: color 0.2s ease; } a:hover { text-decoration: underline; color: #005a9e; } div.dataTables_wrapper div.dataTables_filter input { border-radius: 20px; border: 1.5px solid #0078d4; padding: 6px 15px; font-size: 14px; width: 240px; transition: all 0.3s ease; } div.dataTables_wrapper div.dataTables_filter input:focus { outline: none; box-shadow: 0 0 8px #0078d4aa; border-color: #005a9e; } .dataTables_paginate .paginate_button { background: #0078d4; color: white !important; border-radius: 4px; border: none; padding: 5px 12px; margin-left: 4px; cursor: pointer; transition: background-color 0.3s ease; } .dataTables_paginate .paginate_button.current, .dataTables_paginate .paginate_button:hover { background: #005a9e !important; color: white !important; } p.no-results { text-align: center; font-weight: 600; font-size: 1.1rem; color: #888; margin-top: 40px; user-select: none; } </style> </head> <body> <h2>以下是与指定 Hash 不同的 Favicon 链接</h2> <p class="description">排除的 Hash 值:<strong>{{ hashes }}</strong></p> <div class="table-container"> {% if results %} <table id="hashTable" class="display" style="width:100%"> <thead> <tr> <th>URL</th> <th>Favicon Hash</th> <th>Favicon URL</th> </tr> </thead> <tbody> {% for row in results %} <tr> <td>{{ row.URL }}</td> <td>{{ row['Favicon Hash'] }}</td> <td> <img class="favicon" src="{{ row['Favicon URL'] }}" onerror="this.style.display='none'"> <a href="{{ row['Favicon URL'] }}" target="_blank" rel="noopener noreferrer">{{ row['Favicon URL'] }}</a> </td> </tr> {% endfor %} </tbody> </table> {% else %} <p class="no-results"><strong>没有找到不同的记录。</strong></p> {% endif %} </div> <!-- jQuery --> <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script> <!-- DataTables JS --> <script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> <script> $(document).ready(function() { $('#hashTable').DataTable({ language: { lengthMenu: "每页显示 _MENU_ 条记录", zeroRecords: "没有找到匹配的记录", info: "显示第 _START_ 到 _END_ 条记录,共 _TOTAL_ 条", infoEmpty: "没有记录", infoFiltered: "(从 _MAX_ 条记录中过滤)", search: "搜索:", paginate: { first: "首页", last: "末页", next: "下一页", previous: "上一页" } }, pageLength: 10, lengthMenu: [5, 10, 20, 50], order: [] }); }); </script> </body> </html>