ابدأ بالتواصل مع الأشخاص وتبادل معارفك المهنية

أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.

متابعة

In html ,when we create a form for username and password,when we click submit button where will the link go.How does it works?

user-image
تم إضافة السؤال من قبل Feras Abualrub , Web Solutions Manager , Qistas for Information Technology
تاريخ النشر: 2015/04/19
jean el khoury
من قبل jean el khoury , Full Stack Web Developer , CTServ

The HTML form you created should be linked to a PHP code that executes the action that should be performed.

usually the information entered is also stored in a database using SQL.

 

So in general the HTML is the skeleton of your form, the PHP is the form in action and the SQL Database is where information is stored

geeta sethi
من قبل geeta sethi , faculty , apar india college

<html>

<head> <title> computer </title> </head>

<body> <input type="text"name = username  size =48>Enter the user name

<,br>

<input type = password name = password size =48> Enter the password

<input type = submit name = submit>

,input type = reset name = submit>

</body>

</html>

 

each form have an action, if the action is not specified the form will be submitted to the same oage it was created on.

 

once you specify the action , and submit the form, the username and password will be sent to the receiver action, and thus will be matched against your users database, if a match is found, a session will be created and the user will be logged in, if not match found, an error message would appear with invalid username / password.

 

Shahid Arain
من قبل Shahid Arain

we use an action attribute in form tag which specifies the path to file which will execute after clicking submit. e.g <form method="post/get" action="path/to/the/file"></form>

Asif Ahmed Shoro
من قبل Asif Ahmed Shoro , Senior Full Stack Developer , Netaq ESolution

when html form is used so this form goes two ways when submit button press .In form tag here is action attributes which shows that where we move so here is syntax <form action="abc" > whatever where you move the page and second is if you remain same page so we write like this <form action="#" >  

Muhammad Ahmed Raza
من قبل Muhammad Ahmed Raza , Web Developer & Technical Support Head , Ninja Softs (Private) Limited

Here is an example coding of form submission in HTML:

 

<!---- 

<form action="action_page.php">

First name:<br>

<input type="text" name="firstname" value="Mickey">

<br>

Last name:<br>

<input type="text" name="lastname" value="Mouse">

<br><br>

<input type="submit" value="Submit">

</form>

--->

 

Where action_page.php is your targeted PHP page.

 

basically  the information entered isstored in a database using SQL. The HTML form you created should be linked to a PHP code that executes the action that should be performed.as HTML is the skeleton of your form, the PHP is the form in action and the SQL Database is where information is stored

المزيد من الأسئلة المماثلة

هل تحتاج لمساعدة في كتابة سيرة ذاتية تحتوي على الكلمات الدلالية التي يبحث عنها أصحاب العمل؟