Do a form editing interface for guidance

Source: Internet
Author: User
 
  Edit
 
  

Newcomers just learned PHP not long
The above code is my brain supplement.
The result is that post does not have an incoming value, and the value that is filled in text after clicking submit automatically changes back to the value before the change
Ask for guidance!


Reply to discussion (solution)

if (! $myconn) {
echo "Connection Failed". Mysql_error ();
}

$result =mysql_query ($sql, $myconn);
if (! $result) {
Die (Mysql_error ());
}
Add more MySQL error judgments, so the code is not clear what is wrong.

if (! $myconn) {
echo "Connection Failed". Mysql_error ();
}

$result =mysql_query ($sql, $myconn);
if (! $result) {
Die (Mysql_error ());
}
Add more MySQL error judgments, so the code is not clear what is wrong.


Thanks for the guidance, but the problem is still unsolved.

Your form does not have a submit button, and you do not see the JS code for submission
So $_post is not going to get any data.

Your form does not have a submit button, and you do not see the JS code for submission
So $_post is not going to get any data.


Must the Submit button be written in the form to get the post? Long pose.

Your form does not have a submit button, and you do not see the JS code for submission
So $_post is not going to get any data.


 
  Edit
 
  
 
  

Modified to find only the last row of data in the form was modified after editing
Is it because you chose to print the last line of the form when you made the data changes?
Do you want to change the data by ID?


Your form does not have a submit button, and you do not see the JS code for submission
So $_post is not going to get any data.


 
  Edit
 
  
 
  

Modified to find only the last row of data in the form was modified after editing
Is it because you chose to print the last line of the form when you made the data changes?
Do you want to change the data by ID?


The form you have


This shows only the last data, Ah, the next time the cycle will be the last time the value is overwritten, so it will only modify the final piece of data



Your form does not have a submit button, and you do not see the JS code for submission
So $_post is not going to get any data.


 
  Edit
 
  
 
  

Modified to find only the last row of data in the form was modified after editing
Is it because you chose to print the last line of the form when you made the data changes?
Do you want to change the data by ID?


The form you have


This shows only the last data, Ah, the next time the cycle will be the last time the value is overwritten, so it will only modify the final piece of data


Thank you!
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.