12下一页
返回列表 发帖
查看: 2556|回复: 12

[已解决] dz3.4自适应手机端代码怎么弄的?

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
发表于 2022-8-19 10:37:17 | 显示全部楼层 |阅读模式
网上找到自适应代码放上去都不能用,有没有最新的x3.4自适应手机代码
1 贡献

最佳答案

hcxxw2022 发表于 2022-8-19 11:21
你发的这个能不能用txt打包一下我测试看看 这样太乱了  保存会不会出错,我百度找了狠多都是没用的 ...

这是吾爱破解论坛的自适应,别人发的,没用过
吾爱默认模板自适应css.zip (3.71 KB, 下载次数: 112)
回复

使用道具 举报

10

主题

1332

回帖

2321

积分

应用开发者

DSVUE

贡献
63 点
金币
448 个
QQ
发表于 2022-8-19 10:59:45 | 显示全部楼层
什么样的自适应?
DSVUE-专业建站服务 | 最新DZ插件和模板  | 业务联系QQ:631847671 | 技术支持交流Q群:476397924
承接APP、DZ插件开发、PHP二次开发、网站模板制作、网站搬家、各类网站疑难杂症解决(谢绝担保交易,需支付定金)
回复 支持 反对

使用道具 举报

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
 楼主| 发表于 2022-8-19 11:18:48 | 显示全部楼层
mingkong 发表于 2022-8-19 10:59
什么样的自适应?

代码放入后台统计即可
<script src="https://cdn.bootcss.com/jquery/3.4.1/jquery.slim.min.js"></script>
<script>var jq = jQuery.noConflict();</script>
<script>
    jq(document).ready(function () {
    jq("head").append('<meta name="viewport" content="width=device-width,initial-scale=1,user-    scalable=0">')
    jq("head").append('<style>.tedt{width:100% !important; max-width:600px}</style>')
    jq("head").append('<style>.quote{width:100% !important}</style>')
    jq("#toptb").css("min-width", "0")
    jq(".hdc.cl").css("min-height", "0")
    jq(".wp").css("min-width", "0")
    jq(".zoom").css("width", "100%")
    jq(".zoom").css("max-width", "600px")
    jq(".attach_nopermission.attach_tips").css("width", "100%")
    jq(".attach_nopermission.attach_tips").css("max-width", "600px")
    jq(".tedt.mtn").css("width", "100%")
    jq(".tedt.mtn").css("max-width", "600px")
    jq("#scrolltop").children("span:eq(0)").children("a").attr("onclick", "void(0)")
    resized()
})
window.addEventListener("resize", resized)
function resized() {
    if (jq(document).width() <= 650) {
        jq("#online").hide()
        jq("#qmenu").hide()
        jq("#um").children("p:eq(1)").hide()
        jq("#um").css("padding-right", "0")
        jq("#scbar_txt").css("width", "calc(100vw - 145px)")
        jq(".scbar_hot_td").hide()
        jq(".fl_i").hide()
        jq(".fl_by").hide()
        jq(".hdc.cl").children("h2").children("a").children("img").css("height", "32px")
        jq("#chart").hide()
        jq("#loginstatus").hide()
        jq(".avt.y").hide()
        jq(".y.pns").children("table").children("tbody").children("tr:eq(0)").hide()
            jq(".y.pns").children("table").children("tbody").children("tr:eq(1)").children("td:eq(0)").hide()
            jq(".y.pns").children("table").children("tbody").children("tr:eq(1)").children("td:eq(1)").hide()
        jq("#frt").hide()
        jq(".by").hide()
        jq(".num").hide()
        jq(".bm_h.cl").children(".y").hide()
        jq("#toptb").children(".wp").children(".y").hide()
        jq(".pls").hide()
        jq("#fj").hide()
        jq("#fastsmiliesdiv").hide()
        jq("#fastposteditor").css("margin-right", "0")
        jq("#p_btn").hide()
    } else {
        jq("#online").show()
        jq("#qmenu").show()
        jq("#um").children("p:eq(1)").show()
        jq("#um").css("padding-right", "60px")
        jq("#scbar_txt").css("width", "400px")
        jq(".scbar_hot_td").show()
        jq(".fl_i").show()
        jq(".fl_by").show()
        jq(".hdc.cl").children("h2").children("a").children("img").css("height", "66px")
        jq(".pipe").show()
        jq("#chart").show()
        jq("#loginstatus").show()
        jq(".avt.y").show()
        jq(".y.pns").children("table").children("tbody").children("tr:eq(0)").show()
            jq(".y.pns").children("table").children("tbody").children("tr:eq(1)").children("td:eq(0)").show()
        jq(".y.pns").children("table").children("tbody").children("tr:eq(1)").children("td:eq(1)").show()
        jq("#frt").show()
        jq(".by").show()
        jq(".num").show()
        jq(".bm_h.cl").children(".y").show()
        jq("#toptb").children(".wp").children(".y").show()
        jq(".pls").show()
        jq("#fj").show()
        jq("#fastsmiliesdiv").show()
        jq("#fastposteditor").css("margin-right", "170px")
        jq("#p_btn").show()
    }
}
</script>
回复 支持 反对

使用道具 举报

285

主题

1179

回帖

1569

积分

已臻大成

贡献
3 点
金币
0 个
发表于 2022-8-19 11:18:58 | 显示全部楼层
有人发过,但是没亲自测试,你看看对不对
默认模板自适应css
  1. .designed-by-en{content:"Responsive layout by Coxxs,any unauthorized copying is strictly prohibited.";}.designed-by-zh-cn{content:"响应式布局设计:开源";}#postlist .res-author{display:none;}.tl .res-ti{display:none;}#nv[style*="fixed;"]~#mu{margin-top:33px;}@media (max-width:960px){  #hd .wp,#wp{min-width:initial;}  #jz52top{display:none !important;}    #toptb{min-width:initial;}#toptb .z a[target=_blank]{display:none;}  .comiis_nav{display:none;}  #g_upmine,#extcreditmenu+.pipe{display:none;}  #mn_portal,#mn_N99ef,#mn_N12a7,#mn_home_4,#mn_N34c9{display:none;}    .toptitle_7ree td:last-child,.toplist_7ree .fl_row td:last-child{display:none;}.toptitle_7ree td:nth-last-child(2),.toplist_7ree .fl_row td:nth-last-child(2){border-right:0 !important;}.tipinfo_7ree{display:none;}    #waterfall{height:initial !important;width:100% !important;column-count:3;column-gap:10px;}#waterfall li{width:100% !important;margin:0 0 5px 0;position:initial !important;float:none;display:inline-block;}#waterfall .c{text-align:center;}#waterfall .c .z{float:none;}#waterfall .c .nopic{display:inline-block;}#waterfall .c img,#waterfall .c .nopic{max-width:100%;}  #postlist .plc .t_f img,#postlist .plc .tattl img{max-width:100%;height:auto;}}@media (max-width:650px){  body,input,button,select,textarea{font-size:12px;}body{background-image:none}.bm{border-left:none;border-right:none;}.wp{width:100%;}.ct2,.ct2 .sd{margin-right:0;}.ct2 .sd{float:none;width:100%;}  .nc-container #nc_1_wrapper,.nc-container.tb-login #nc_1_wrapper,.nc-container #nc_2_wrapper,.nc-container.tb-login #nc_2_wrapper,.nc-container #nc_3_wrapper,.nc-container.tb-login #nc_3_wrapper{width:235px !important;}    .hdc h2 a img{height:32px;}#hd h2{padding-right:0;}  #toptb{display:none;}  .scbar_narrow #scbar_txt,#scbar_txt{width:calc(100vw - 135px);}.scbar_hot_td{display:none;}    #um > p{font-size:0;}#um > p a{font-size:12px;text-shadow:0 0 2px white;}  #um > p .pipe{margin:0 1.5px;font-size:12px;visibility:hidden;}  #um .avt{display:none;}#um{padding-top:1px;padding-right:7px;}#um #myitem,#um #myitem+.pipe{display:none;}#um > p{float:right;}#um > p a[href="portal.php?mod=portalcp"],#um > p a[href="portal.php?mod=portalcp"]+.pipe,#um > p a[href="connect.php?mod=config"],#um > p a[href="connect.php?mod=config"]+.pipe{display:none;}#um p:last-child{display:none;}.vwmy,.vwmy.qq{background:none;padding-left:0;}#um #loginstatus{padding-left:6px;}.hdc{min-height:40px;}  #hd .fastlg_fm{display:none;}#hd .fastlg{padding-top:3px;padding-right:10px;}#hd .fastlg table tr:first-child{display:none;}#hd .fastlg table tr:last-child td:first-child{display:none;}#hd .fastlg table tr:last-child td:nth-child(2){display:none;}  #pt .y{display:none;}#pt{padding-left:5px;height:auto;}.pg_viewthread #pt .z > a:last-child,.pg_viewthread #pt .z > em:nth-last-child(2){display:none;}  #mn_forum_11,#mn_N05be,#mn_Na678{display:none;}  #hd #nv > a:last-child{display:none !important;}  #nv{position:initial !important;width:initial !important;padding-left:6px;border:none !important;opacity:1 !important;}#mu{margin-top:0 !important;}  #qmenu_menu{width:300px;height:auto;}#fjump_menu{display:none;}    #chart .chart.z,#chart .y{display:none;}        #toplistbox_7ree .bm_h+div{overflow-y:hidden;overflow-x:auto;}#toplistbox_7ree .toptitle_7ree td{min-width:50vw;}.boxbg_7ree{background:none !important;padding-left:0 !important;}  .fl .fl_tb h2 > a,.fl .fl_tb dt > a{font-size:14px;}.fl .fl_tb .fl_g dl dd:last-child{display:none;}.fl .fl_tb tr td.fl_g{display:block !important;width:100%;}.fl .fl_tb tr td.fl_g:empty{display:none !important;}.fl .bm_c .fl_tb tr .fl_i,.fl .bm_c .fl_tb tr .fl_by{display:none;}.fl .fl_tb tr td.fl_g,.fl_row td{border-top:1px solid #EEEEEE;}.fl .fl_tb tr:first-child td.fl_g:first-child{border-top:0;}  .fl .bm_h .y{display:none;}  .boardnav #ct .bm_h .xs1.xw0{display:none;}.f_c .list{width:350px;}.floatwrap{height:200px;}  #thread_types.ttp{border:none;padding:0 0 0 8px;}.ttp .num,#thread_types .fold{display:none;}    .tl .bm_c{padding-left:2px;padding-right:2px;}.tl .tps,.tl .tps+a.xi1,.tl .res-ti+a.xi1{display:none;}.tl .showhide{margin-right:0;margin-top:14px;}.tl .th tr .by,.tl .th tr .num,.tl table tr .by,.tl table tr .num{display:none;}.tl table tr > th > img{display:none;}.tl table tr th{width:100%;}.tl .icn{padding-left:9px;}.tl th{padding-left:3px;}.tl th,.tl td{border-bottom:1px solid #E0E0E0;padding-top:8px;padding-bottom:8px;}.tl .o{width:24px;}#threadlist.tl tbody:last-child th,#threadlist.tl tbody:last-child td{border-bottom:none;}  .tl .res-ti{display:block;color:#999;margin-top:2px;}.tl .res-ti > a{color:#999 !important;}  .pcht{max-width:100%;}    #waterfall{column-count:2;column-gap:6px;margin-left:5px;margin-right:5px;width:auto !important;}#waterfall .nopic{height:80px !important;}  .tl table tr > th > img[src$="/stamp/004.small.gif"],.tl table tr > th > img[alt="digest"]{display:inline;}  #postlist{border-bottom:none;}  .pg_viewthread #newspecial,.pg_viewthread #post_reply,.pg_viewthread #newspecialtmp,.pg_viewthread #post_replytmp{display:none;}  #postlist .pls{border:none;background:transparent;}#postlist .ad .pls{background:#E5EDF2;}  #postlist .pls{width:46px;text-align:center;}#postlist .res-postfirst .pls{width:0;}#postlist .favatar.pls{position:initial !important;}#postlist .favatar.pls > *{display:none;}  #postlist .favatar.pls{padding-top:10px;}#postlist .favatar.pls > .pi .authi{display:none;}      #postlist .favatar.pls > .bui+div{display:block;}#postlist .favatar.pls .avatar{margin:0;}#postlist .favatar.pls .avatar img{padding:0;margin:0 0 0 10px;background:none;width:36px;height:36px;border-radius:100%;}      #postlist .sign{display:none;}  #postlist .res-author{display:inline;font-weight:bold;}#postlist .pti .authi .poston,#postlist .pti .authi .firstauthor{display:none;}#postlist .pti .authi{opacity:.7;display:inline;}#postlist .pti .authi font[color=red]{display:none;}#postlist .pti .authi .authicn{display:none;}#postlist .pti .authi > .pipe,#postlist .pti .authi > a,#postlist .pti .authi > .none,#postlist .pti .authi > .xg1{display:none;}#postlist .pi{border-bottom:none;margin-bottom:0px;}  #postlist > table:first-child .pls{display:none;}#postlist > table:first-child .plc{padding:10px 10px !important;}#postlist > table:first-child .plc h1.ts{font-size:15px;}#postlist > table:first-child .plc .y{display:none;}#postlist > table:first-child .plc .xg1{font-size:0;}#postlist > table:first-child .plc .xg1 img{display:none;}#postlist > table:first-child .plc .xg1 a{font-size:12px;}  #postlist .plc{padding-left:12px;padding-right:12px;}#postlist .plc .t_f{}#postlist .plc .t_f img[smilieid]{zoom:.7;}#postlist .plc .tattl{width:100%;}#postlist .plc .t_fsz{min-height:30px;}#postlist .plc .po{border:none;}.pl .quote{margin-left:-58px;background-position-x:55px;margin-right:-12px;padding-left:92px;}.pl .quote blockquote{padding-right:29px;}  #postlist #recommend_add,#postlist #recommend_subtract,#postlist .followp{display:none;}      #postlist .replysubtract{display:none;}  #postlist .bdsharebuttonbox{display:none;}  #threadstamp{transform-origin:right;transform:scale(.5);opacity:.7;}  .mobile-type{display:none;}  .psth{margin-left:0px;border-left:3px solid #F26C4F;width:180px;padding-left:15px;}.psth .icon_ring{display:none;}#postlist .rate .ratl tr th{width:22px;}#postlist .rate .ratl tr th:first-child{font-size:0;width:60px;}#postlist .rate .ratl tr th:last-child{width:80px;}#postlist .rate .ratl tr th .xi1{display:none;}#postlist .rate .ratl tr td.xg1{white-space:normal;}  #fwin_rate input[name="reason"]{width:80px;}  .psta{width:70px;}.psta > a > img{display:none;}.psti{margin-left:70px;}  #modmenu{padding:0 10px;text-align:center;line-height:1.8em;margin-top:-5px;margin-bottom:-5px;}#modmenu a{display:inline-block;color:#AAA;}#modmenu .pipe{display:inline-block;transform:scale(.5);color:#DDD;}.pg_viewthread #mdly{z-index:200 !important;}#postlist .plc .po .y > label{font-size:0;margin-left:2px;margin-right:2px;}#postlist .plc .po .y > label > input{}#postlist+.mbm.pbm.bbs{display:none;}  #f_pst{border-bottom:none;}#f_pst .pls{display:none;}#f_pst .plc{padding:5px 8px 0 8px;}#f_pst .pnpost > a{display:none;}  #f_pst #fastpostmessage{background:#FFF !important;}#f_pst #fastsmiliesdiv{display:none;}#f_pst .hasfsl{margin-right:0;}  .m_c .quote{width:295px !important;}.m_c .tedt{width:310px;}#fwin_content_comment .o span.z{font-size:12px;}#fwin_content_comment .o span.z .xs2{font-size:12px !important;}.fwin .rfm,.nfl .f_c .rfm{width:365px;}  .voterlist{max-width:80vw;}  .t_f ignore_js_op > span[id^="attach_"]{font-size:14px;white-space:normal !important;}  #pgt,.pgs{padding-left:8px;padding-right:8px;}#pgt .pg,#pgt .pgb{margin-top:0;}.pg > a{display:none;}.pg > strong+a,.pg > a:nth-last-child(3){display:inline;}.pg > .first,.pg > .prev,.pg > .prev+a,.pg > .last{display:inline;}.pg > a.nxt{display:block;font-size:0;padding-right:0;width:12px;background-position:center;}.pgb a{padding-left:15px;padding-right:5px;margin-left:0;background-position:1px 50%;}.pg label{padding-left:4px;padding-right:4px;}.pgbtn a,#autopbn{border-radius:0 !important;border-left:none !important;border-right:none !important;}.pgs #newspecial,.pgs #newspecialtmp,.pgs #post_reply,.pgs #post_replytmp{margin-right:0;}.pgs #newspecial img,.pgs #newspecialtmp img,.pgs #post_reply img,.pgs #post_replytmp img{height:28px;}    #category_lk .lk_logo p{display:none;}  #online.oll{display:none;}  #ft{padding-top:12px;padding-bottom:12px;}#ft:after{content:"";}#flk{float:none;text-align:center;}#frt,#flk .xs0{display:none;}#flk strong:after{content:" ";display:block;}  #ft{background:#F3F3F3;border-top:1px solid #E3E3E3 !important;color:#999;}      .res-footer-note{padding:0 10px;}  #ct.ct2_a{min-height:auto;}.ct2_a .mn{display:inline-block;box-sizing:border-box;width:100%;margin-left:8px;margin-right:8px;float:none;}.tfm .pt,.tfm .px{width:150px;}.tedt .pt{width:100%}#td_timeoffset select{width:150px;}.ct2_a{display:flex;flex-wrap:wrap-reverse;padding-left:0;background:none;border:none;}.ct2_a.cl:after{content:none;}.ct2_a .appl{display:inline-block;box-sizing:border-box;width:100%;margin:3px 0 5px 0;background:#F6F6F6;border:none;}.appl{float:none;}.appl .tbn .bbda{background:#F0F0F0;margin-bottom:3px;text-align:center;font-weight:normal;border-bottom:none;}.ct2_a .appl .tbn li{border:none !important;float:left;}.ct2_a .appl .tbn li a{color:#777;}.ct2_a .appl .tbn li.a{font-weight:bold;margin-top:0;background:none;}.ct2_a .appl .tbn li.a a{color:#444;}.tbn ul a{display:inline-block;}.pm_op_r{padding-right:10px;}.tb a{padding-left:7px;padding-right:7px;}.pg_spacecp .bm2 .bm2_b,.pg_spacecp .bm2 .bm2_b_y{float:none;width:auto;}.pg_spacecp .bm2 .bm2_b_y{margin-top:15px;}  .pg_task .ptm tr > .hm,.pg_task .ptm tr > .bbda[width="80"]{display:none}.pg_task .ptm tr > .bbda[width="120"]{width:100px;text-align:center;}  #uhd .flw_hd{width:auto;margin-bottom:0;}#uhd .flw_hd .o{margin-top:0 !important;}#uhd .mn{line-height:22px;}#uhd .tns th,#uhd .tns td{padding-left:7px;padding-right:7px;}  .pm{width:345px;}.pmb{width:315px;padding:15px 15px 0;height:180px;}.pmform .px{width:190px !important;}.pmform .tedt{width:auto !important;}.pmform th{width:50px;}  .pg_modcp .ct2_a .mn{margin-left:5px;margin-right:5px;}.pg_modcp .ct2_a .tbn > ul > li > .mtn{margin-left:3px;margin-top:3px !important;}.pg_modcp .exfm table tr{display:flex;flex-flow:row wrap;}.pg_modcp .exfm table tr th{flex-basis:25%;}.pg_modcp .exfm table tr td{flex-basis:70%;}.pg_modcp .tl table tr td:not([class]){width:100%;}.pg_modcp .tl table tr td.o{width:30px;padding-left:10px}#reportform{overflow-x:scroll;}#list_modcp_logs .td,#list_modcp_logs .th{padding:7px 10px;}  .rfm{width:auto;}.rfm th{width:6em;}  .nfl .f_c{width:95%;box-sizing:border-box;}  .fwinmask{margin-top:-20px;}.reason_slct .reasonselect{height:5.8em !important;}  .fwinmask textarea[name="message"]{max-width:85vw;}  font[size]{font-size:23px;}font[size="1"]{font-size:12px;}font[size="2"]{font-size:14px;}font[size="3"]{font-size:16px;}font[size="4"]{font-size:18px;}font[size="5"]{font-size:20px;}font[size="6"]{font-size:21px;}font[size="7"]{font-size:23px;}}
复制代码


静能挂机骂队友,动能千里送人头
问君能有几多愁,五人四坑二十投
回复 支持 反对

使用道具 举报

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
 楼主| 发表于 2022-8-19 11:19:19 | 显示全部楼层
就是去除默认的手机版,手机打开网站就是一个缩小的电脑版
回复 支持 反对

使用道具 举报

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
 楼主| 发表于 2022-8-19 11:20:13 | 显示全部楼层
mingkong 发表于 2022-8-19 10:59
什么样的自适应?

f0a7806231edaa6b260a8e153a354c00.png 这样类型的
回复 支持 反对

使用道具 举报

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
 楼主| 发表于 2022-8-19 11:21:33 | 显示全部楼层
ysx24 发表于 2022-8-19 11:18
有人发过,但是没亲自测试,你看看对不对
默认模板自适应css

你发的这个能不能用txt打包一下我测试看看 这样太乱了  保存会不会出错,我百度找了狠多都是没用的
回复 支持 反对

使用道具 举报

285

主题

1179

回帖

1569

积分

已臻大成

贡献
3 点
金币
0 个
发表于 2022-8-19 11:30:34 | 显示全部楼层
hcxxw2022 发表于 2022-8-19 11:21
你发的这个能不能用txt打包一下我测试看看 这样太乱了  保存会不会出错,我百度找了狠多都是没用的 ...

这是吾爱破解论坛的自适应,别人发的,没用过
吾爱默认模板自适应css.zip (3.71 KB, 下载次数: 112)
静能挂机骂队友,动能千里送人头
问君能有几多愁,五人四坑二十投
回复 支持 反对

使用道具 举报

11

主题

30

回帖

58

积分

渐入佳境

贡献
1 点
金币
1 个
 楼主| 发表于 2022-8-19 11:37:16 | 显示全部楼层
ysx24 发表于 2022-8-19 11:30
这是吾爱破解论坛的自适应,别人发的,没用过

有没有说放在哪个位置?
回复 支持 反对

使用道具 举报

285

主题

1179

回帖

1569

积分

已臻大成

贡献
3 点
金币
0 个
发表于 2022-8-19 13:26:03 来自手机 | 显示全部楼层
hcxxw2022 发表于 2022-8-19 11:37
有没有说放在哪个位置?

应该是替换默认模板css  怎么不用自适应,不清楚
你试下吧
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

  • 关注公众号
  • 有偿服务微信
  • 有偿服务QQ

手机版|小黑屋|Discuz! 官方交流社区 ( 皖ICP备16010102号 |皖公网安备34010302002376号 )|网站地图|star

GMT+8, 2024-5-3 16:43 , Processed in 0.051557 second(s), 9 queries , Redis On.

Powered by Discuz! W1.0 Licensed

Cpoyright © 2001-2024 Discuz! Team.

关灯 在本版发帖
有偿服务QQ
有偿服务微信
返回顶部
快速回复 返回顶部 返回列表