小编mal*_*lik的帖子

如何在nodejs模型中获取用户ip?并在我的表格列ip_address中更新

我想在模型中编写函数以获取用户ip,并希望存储在用户表中的节点js中具有列名ip_address。(使用express,mysql)

  User.prototype.userip= function(req, res)
  {
    // here need access to IP address here
  }
Run Code Online (Sandbox Code Playgroud)

node.js express

2
推荐指数
1
解决办法
49
查看次数

标签 统计

express ×1

node.js ×1