What is the principle of obtaining the last login IP?
海|Xian生
海|Xian生 2020-05-15 11:44:55
0
6
1571

What is the principle of obtaining the last login IP?

海|Xian生
海|Xian生

reply all(3)
Storms

Database fields can be added, created, named,

  • reply However, the teacher did not add this field. What is obtained through the request object is the IP address of this login.
    海|Xian生 author 2020-05-16 15:32:50
哈比

Re-create a login record table and save the information about each successful login to the database. When you log in next time, just go to the database to get the previous information of the current login record. To put it simply, for example, the database has 3 entries. Data, when I logged in, a new one was added to the database, four together, with IDs 1, 2, 3, and 4; the current login record ID is 4, so I searched for an ID record one level smaller than 4. That’s it

  • reply The data table does not save the IP field
    海|Xian生 author 2020-05-15 14:44:44
对方正在输入....

Every time you log in, the current IP is stored in the database.

  • reply Can I use the request object to obtain database information?
    海|Xian生 author 2020-05-15 12:34:18
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template