我知道因为静态网页要比动态网页快,所以我们登录一些大网站的时候,地址的后缀名是.html。可是,为什么这样的静态网页,仍然能识别我们的登录呢?我们的用户名不一样,看见的网页就不一样。可是明明是html啊?求教啊!

解决方案 »

  1.   

    那是经过 rewrite 的,伪静态
      

  2.   


    就是
    雖然看起來是訪問 index.html 
    但是,經過 rewrite URL 之後 ( 這一步,  規則是由你定的 , server 進行處理的 )
    就變成 是訪問 index.php
      

  3.   

    前台状态标识也可能是JS读COOKIE做的。后台验证操作还是通过session判断的。
      

  4.   

        rewrite ^/(post|record|sort|author|page)-([0-9]+)\.html$ /index.php?$1=$2;
      

  5.   

    http://xxxx/post-11.html http://xxxx/index.php?post=11 
      

  6.   

    比如你所在网页是 index.html
    可能是经过服务器的rewrite 到index.php 处理
      

  7.   

    其实也不一定是伪静态...
    有可能也是
    <form id="form1" action="index.php" method="post" enctype="multipart/form-data">
    ......
    </form>
    这也是一种情况,不过比较少...
      

  8.   

    我模糊的影像中,你可以自己定义以什么后缀名结尾,就比如你可以把index.html定义成index.sb结尾一般.好神奇好神奇...