Php performs webpage login pages and transmits data. if the variable is invalid, the problem is solved.

Source: Internet
Author: User
Php performs webpage login pages and transmits data. if the variables are invalid, the PHP login interface is solved.

Php sets a total of three variables, and found that only $ select is valid at the time of determination, and the other two are invalid. what is the problem?
Please answer your questions and hurry up with the task.
I am very grateful for your help.
Logon interface code:



Untitled Document













Southwest China University for Nationalities





Lab teaching management system















  User logon





 


 




Php detection code:

@ $ Textfield =$ _ POST ['textfield'];
@ $ Textfield2 = $ _ POST ['textfield2'];
@ $ Select = $ _ POST ['select'];
If ($ textfield = "a") & ($ textfield2 = "123") & ($ select = "B") // enter, 123. invalid instructor selection. remove any
Echo"

Fffffff

"; // Condition. if any data is input, it is found that ($ select =" B ") is valid,
Else // The other two statements are useless and must be false.
Header ("Location: http: // localhost/phpmyadmin/Documentation.html ");
Exit;
?>


Reply to discussion (solution)

How many forms do you want to write !!!

How many forms do you want to write !!!
Do not understand?

A form is OK. keep the first form and delete all the other forms.

That's it.

 Untitled Document
 
 
Southwest China University for Nationalities
Lab teaching management system
  User logon

 

 

You have to go against the sky. in a text box and a form, you can directly put the form on the outer layer of the table. you only need one form.

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.