Hello, My self Arpan Tiwari And today I am going to share another topic in web development . I have completed this lecture by Sanket sir from pw skills And this snippet includes about get and posts methods, different another types of input attributes and so on..
As we are already familiar with forms in HTML so the question is how we told the server to submit the form and where ?? This was solved by using one of attribute that is "method" .. Now with method we use two types of request one is get request and other is post request.. Now the question is what are the difference between these two??..
In case of get request the server read the data through u.r.l. that is your submitted data go further through url.. But in case of post it do not use u.r.l. and directly transfer to server side.. disadvantage of using the get is all your data can be catch as your data will remain in your history with password so anyone can misuse it.. on the other hand advantage is it is very easy to use..
<form method="get">
But in case of post it is very secure.. as when we are using post then during form submission there is another body created which help in submission and after submission it erase out.. In case of post request you can also use target attribute that will provide you an extra page to submit the form..
<form method="post" target="_blank" action="/signup">
The another concept is different types of inputs like placeholder, read only, value, disabled, and so on.. placeholder input attribute is basically used to give the hint to the users.. value is also used to write input already like name is already written in name box just to give the hint to user.. When you are using read only attribute with input that is already written then user cannot erase it and disabled gives the faint color to already things..
<input type="email" name="email" id="useremail" placeholder="username@gmail.com">
<input type="name" id="name" name="username" value="Name" readonly disabled>
So this was all about this snippet and I hope It will be helpful for you.. Thank you..