Personal idea:
You identified users only by IP ,what about the following ...
1)A user login from diffent ip with the same username?
2)many users in a lan behind a firewall,they use the same outer IP?
There are always other unknowable situations.

解决方案 »

  1.   

    Thanks for your reply...
    For I am a freshman in PHP,so always I ignore important situations as you told me.
    I will consider fix it with username & IP identification.
    I like this place for I can always learn things here and get help from friends like you are.Thanks!
    Rainman