- 新增 /template/default/common/extend_common.css 文件放入如下代碼:
- body, #toptb {min-width: 0 !important}
- .wp {width: 1200px !important; max-width: 100% !important}
- img.zoom, #e_image_menu {max-width: 100% !important; height: auto !important}
- .btn_s_open, .btn_s_close, #qmenu {display: none !important}
- .pcht {max-width: 100%}
- .a_t td {padding: 4px !important}
- ul.xl.xl2.o.cl { display: none !important }
- @media (max-width: 767px) {
- .m_c .tedt, #subjecthide, .m_c .quote, .rfm {width:100%!important}
- #frt, .fl_i, .num, #boardlogo, .category_l3, .pls, tr td:nth-last-child(3).by, tr.ts td:nth-last-child(-n+2) {display: none !important}
- #scbar_txt, .ct2_a .mn, .f_c.altw, .c, .f_c .list {width: auto !important}
- #wp, #ft, .hdc.cl {padding: 0 10px !important; box-sizing: border-box}
- .rfm th {width: 5em !important}
- .pm {width: 360px !important}
- .ptm img {max-width: 100% !important}
- }
- @media (max-width: 392px) {
- .fl_by {display: none !important}
- }
複製代碼
- 修改 /template/default/common/header.htm 文件,在其 </head> 標籤前添加代碼
- <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, viewport-fit=cover">
複製代碼
- 後臺統計代碼增加
- <script>
- const mobileWidth = 767
- if (window.innerWidth<=mobileWidth) {
- if (!document.cookie.includes('close_leftinfo=1')) {
- setcookie('close_leftinfo', 1)
- location.reload()
- }
- } else {
- if (document.cookie.includes('close_leftinfo=1')) {
- setcookie('close_leftinfo', 2)
- location.reload()
- }
- }
- </script>
複製代碼
- 站點寬窄風格改成窄屏(固定寬度),允許用戶自由切換改成否
- 作者用戶名顯示位置改成顯示在帖子內部
- 快速發帖右側顯示推薦表情改成否
- 左側信息欄允許用戶控制 改為 是
- 僅適用於Discuz! X3.5默認主題,不適用3.4
- 如果沒有生效,後臺更新一下模板的CSS緩存
|