Enable or disable sorting of columns
Sorting of individual columns can be disabled by the “bSortable” option for each column.
Note that this will disable sorting all around, so there is no need to disable it on individual columns Continue reading
You can calculate the Image dimension and determine if the image orientation is landscape or portrait using jQuery. You can also calculate using packages like ‘RMagick’, ‘MiniMagick’ in ruby ( ROR ). However it has following disadvantages:
HTML forms (up to HTML version 4 and XHTML 1) only support GET and POST as HTTP request methods. A workaround for this is to tunnel other methods through POST by using a hidden form field which is read by the server and the request dispatched accordingly.
However, GET, POST, PUT and DELETE are supported by the implementations of XMLHttpRequest (i.e. AJAX calls) in all the major web browsers (IE, Firefox, Safari, Chrome, Opera).
You use Rails4ClientSideValidation gem to validate you forms.
When you programatically change the values of the required fields or any fields with some sort of validation such as ’email’ or ‘phone_number’, the validation message does not disappear.
jQuery.extend( target [, object1 ] [, objectN ] )
Keep in mind that the target object (first argument) will be modified, and will also be returned from
If, however, you want to preserve both of the original objects, you can do so by passing an empty object as the target: