How to use jQuery to intercept form submissions and validate form input

There came a time where I had to create a HTML form to accept inputs from users in order to generate a report. Before submitting the form to the back end server, there are some validations that I can perform on the data at the client side to reduce the number of HTTP responses that my server had to generate for unwanted inputs. The cost savings is especially significant when the form submission contains large file as part of the HTTP request.

I chose to use jQuery for intercepting the form submissions and do some data validation before I allow the browser to create a HTTP request to the server. This post documents a proof of concept, as a stepping stone, to realize my objective.

How to read values from a properties file located within a Java jar file

A good programming practice will be to code applications to read from a text file for values which are expected to change often. Java Swing applications are often packed in a single jar file and it can make deployment easier if our Java Swing applications can read from text files embedded within the same jar file that they reside in.

There came a time where I need to code a Java applet to read i18n labels from some properties files. This post documents my proof of concept before I embark in coding that Java applet.