dre4m
V2EX  ›  站长

主站和移动站分数不同 IP 的非 JS 写法

  •  
  •   dre4m · Jul 20, 2019 · 2960 views
    This topic created in 2565 days ago, the information mentioned may be changed or developed.

    比如 PHP 的,希望主站和移动站分属不同 IP 地址。源码里不想体现。问题是:

    1,主站和移动站是分离的,两个独立页面,请问如何实现?(这个应该简单一点)

    2,主站是自适应的,请问如何实现? ( CSS 里应该没法实现,不希望用 JS 判断)

    非常感谢~!

    3 replies    2019-07-20 19:57:07 +08:00
    rzti483NAJ66l669
        1
    rzti483NAJ66l669  
       Jul 20, 2019   ❤️ 1
    在 Web Server 实现
    dre4m
        2
    dre4m  
    OP
       Jul 20, 2019
    @Humorce 有没有 ngnix 的大概思路,能否给简单说下,或更懒一些,哪些 web 面板支持这个功能呢?
    rzti483NAJ66l669
        3
    rzti483NAJ66l669  
       Jul 20, 2019   ❤️ 1
    @dre4m #2

    判断 UA
    https://www.google.com/search?q=nginx+desktop+mobile

    面板不知道,很少使用到面板。
    nginx 配置也就几行。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2971 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 14:45 · PVG 22:45 · LAX 07:45 · JFK 10:45
    ♥ Do have faith in what you're doing.