The amazing technical experts who have never seen them come to watch !!! Mysql automatically inserts two data records at a time to solve the problem .... At the end of this post, helpmbbm will edit mysql_connect (XXX.com, XXX, XXX); mysql_select_db (XXX); mysql_query (set & nbsp; the amazing technical experts who have never seen the name come to watch !!! Mysql automatically inserts two data records at a time to solve the problem ....
This post was last edited by helpmbbm at 02:08:16
Mysql_connect ("XXX.com", "XXX", "XXX ");
Mysql_select_db ("XXX ");
Mysql_query ("set names 'utf-8 '");
$ Ip = "222 ";
$ Insql = "insert into 'IP' ('IP') VALUES ('$ IP ')";
Mysql_query ($ insql );
Php code of all pages is not html, no form is not include ....
But insert two identical entries at a time...
I have removed all the code for getting IP addresses. all the code is above. now it's amazing that two pieces of data are inserted at a time to set the value of the variable ip address to 222, you also get a local IP address that is not obtained in any way !!!!!
I thought it was a ghost cache and changed the IP address, and inserted two more, and it was a new IP address and 222.
Is it possible to obtain the built-in variable $ Ip ?? Change to $ iip and insert two ,,
Okay, change the SQL statement ID to $ insql = "INSERT INTO 'IP' ('id', 'IP') VALUES ('null ','". $ iip. "');";
In a magic result !!!!
I'm dreaming ??? I met a ghost ???
Table structure
Create table 'IP '(
'Id' int (8) not null,
'IP' varchar (20) NOT NULL
) ENGINE = InnoDB default charset = utf8;
Finally, I tried to insert only one piece of data, instead of inserting a magic IP address. After I changed the table name to an IP address, I still couldn't help but explain it to someone else .. Without any code to obtain the ip address .. Why can I get a magic IP address and insert 2 .....
After the refresh is performed, two more entries are inserted. The table name is ipip. Which of the following is an SQL statement saved ????
However, I have no way to obtain the IP address .. No framework or external files are introduced...
I want someone to believe that what I'm talking about is true? This is true ..
I can't figure it out, afraid of my own illusion .... or dreaming .. then I beat myself .. then debug the same job locally and insert a normal one, solve the magic cache technology of the above application ........................... and how to insert only one .......
The problem has been found. each person gives three chances to guess. What is the cause? I don't believe someone can guess it !! Haha
------ Solution --------------------
Try Me