Home > front end >  Nodejs for help
Nodejs for help

Time:09-24

Would you please tell me why, with the req id name in the address bar. The body will not the same in the

Was supposed to be contentid and content, don't know why become commentid

CodePudding user response:

Brother url? Id=XXX this but get ah, the corresponding is the req. Query
And the req. The body is the corresponding post the Form Data

//the req. BaseUrl based routing address
//the req. Body post to send data parsing out object
//the req. Cookies client sends cookies data
//the req. The hostname host address get rid of port
//the req. IP to check the client's IP address
//the req. The IP address of the ips agent
//the req. OriginalUrl on the req. A backup url
//the req. Params in use/: : id/name matching params
//the req. Path contains the path of the request URL section
//the req. HTTP or HTTPS protocol agreement
//the req. Query query string objects of parsing out the username=zhangsan& Password=123 {username: zhangsan}
//the req. The route of the current regular expression matching route
//the req. Params for routing matching parameter
//the req. Get access to the parameters in the request header
//the req. Is to see what kind of the request file
//the req. Param name (key) is used to obtain a routing matching parameters

CodePudding user response:

reference 1st floor SCSCMS sunlight response:
laoge url? Id=XXX this but get ah, the corresponding is the req. Query
And the req. The body is the corresponding post the Form Data

//the req. BaseUrl based routing address
//the req. Body post to send data parsing out object
//the req. Cookies client sends cookies data
//the req. The hostname host address get rid of port
//the req. IP to check the client's IP address
//the req. The IP address of the ips agent
//the req. OriginalUrl on the req. A backup url
//the req. Params in use/: : id/name matching params
//the req. Path contains the path of the request URL section
//the req. HTTP or HTTPS protocol agreement
//the req. Query query string objects of parsing out the username=zhangsan& Password=123 {username: zhangsan}
//the req. The route of the current regular expression matching route
//the req. Params for routing matching parameter
//the req. Get access to the parameters in the request header
//the req. Is to see what kind of the request file
.//the req param name (key) used to obtain a certain route matching parameter


Big good, I am using a post request, but I use the req. Body. The contentid complains, with req.body.com mentid is no problem, why is this? I was just a small white, give advice or comments please bosses of
  • Related