All Questions

44
votes
1answers
50771 views

Servlet returns "HTTP Status 404 The requested resource (/servlet) is not available"

I have an HTML form in a JSP file in my WebContent/jsps folder. I have a servlet class servlet.java in my default package in src folder. In my web.xml it is mapped as /servlet. I have tried several U...
27
votes
4answers
5087 views

POST a form array without successful

I'm developing an ASP.NET MVC 5 web with C# and .NET Framework 4.5.1. I have this form in a cshtml file: @model MyProduct.Web.API.Models.ConnectBatchProductViewModel @{ Layout = null; } <!D...
556
votes
25answers
388869 views

Prevent users from submitting a form by hitting Enter

I have a survey on a website, and there seems to be some issues with the users hitting enter (I don't know why) and accidentally submitting the survey (form) without clicking the submit button. Is the...
251
votes
4answers
336465 views

Uploading both data and files in one form using Ajax?

I'm using jQuery and Ajax for my forms to submit data and files but I'm not sure how to send both data and files in one form? I currently do almost the same with both methods but the way in which the...
505
votes
69answers
307641 views

Disabling Chrome Autofill

I have been running into issues with the chrome autofill behavior on several forms. The fields in the form all have very common and accurate names, such as "email", "name", or "password", and they a...
185
votes
15answers
134696 views

When should I use GET or POST method? What's the difference between them?

What's the difference when using GET or POST method? Which one is more secure? What are (dis)advantages of each of them? (similar question)
605
votes
13answers
455696 views

How to prevent buttons from submitting forms

In the following page, with Firefox the remove button submits the form, but the add button doesn't. How do I prevent the remove button from submitting the form? <html> <head> <script ...
219
votes
37answers
255099 views

Post the checkboxes that are unchecked

I've got a load of checkboxes that are by default checked. My users will probably uncheck a few of the checkboxes (if any) and leave the rest of them checked. Is there any way to get the checkboxes ...
148
votes
7answers
252416 views

How to prevent form from being submitted?

I have a form that has a submit button in it somewhere. However, I would like to somehow 'catch' the submit event and prevent it from occurring. Is there some way I can do this? I can't modify the ...
129
votes
6answers
381614 views

Get $_POST from multiple checkboxes

I have 1 form in with multiple checkboxes in it (each with the code): <input type="checkbox" name="check_list" value="<? echo $row['Report ID'] ?>"> Where $row['Report ID'] is a primary...

Previous Next