• Javascript

  • 179__javascript.gif Litte javascript code snippets very useful!

 

Intro

A small introduction to javascript

See more..

 

parseInt with leading zero

parseInt with a string that begins by 0 makes the radix be octal and not decimal, there are two solutions:

See more..

 

Lightbox Single Image with Bootstrap with Thumbnail

How to use Bootstrap modal to create a lightbox with a full size image inside by clicking on its thumbnail to open it.

See more..

 

Javascript: Fill in two select input dynamically

How to fill in dynamic select and when you select a value in select1 that reload new values in select2

See more..

 

Make a checkbox check or uncheck a group of checkboxes

In your form you want to check/uncheck a group of checkboxes by clicking in one checkbox, see the code..

See more..

 

Upload file without submit button

How to upload a file without the submit button

See more..

 

Form validation with prototype

An interesting form validation script with prototype

See more..

 

Ajax multiple selects with radio buttons

This is a really nice ajax control

See more..

 

Getting multiple values from a select input element

When you need to retrive several values from a select with the attribute MULTIPLE

See more..

 

Check box validation

Validate a list of checkboxes before submitting a form, even if there is only one checkbox in the list

See more..

 

JQuery Check/Uncheck a checkbox group

Check/Uncheck a checkbox group using JQuery

See more..

 

JQuery Show Hide Div with a Plus Sign

Show/Hide a div with JQuery Javascript library

See more..

 

DataTables jQuery Making Some Columns Editable

How to make editable certain columns with DataTables jQuery plugin, without having to implement the whole row CRUD code for every field.

See more..

 

Comparing Dates

A little function in Javascript that compares two dates: if the field date is older than current date, an alert is shown.

See more..