Monthly Archive: July 2013

How to create a ‘select all’ checkbox in javascript 0

How to create a ‘select all’ checkbox in javascript

For HTML Code: <input type=”checkbox” onClick=”toggle(this)” /> <input type=’checkbox’ name=’ss’ value=’one’ /> <input type=’checkbox’ name=’ss’ value=’two’ /> <input type=’checkbox’ name=’ss’ value=’three’ /> We use Javascript: <script> function toggle(source) { checkboxes = document.getElementsByName(‘ss’); for (var...

How to get a previous date in bash (linux) 0

How to get a previous date in bash (linux)

Simply put date -d ‘1 day ago’ +’%Y-%m-%d’ # For multiple days date -d ‘7 days ago’ +’%Y-%m-%d’ If you wish to place in a shell script: RMDATE=$(date -d ‘7 days ago’ +’%Y_%m_%d’) will...