Displaying posts categorized under

RJSLIB

Ram JavaScript Library

Collapsed Divs

Collapsible Div – Vertical Collapse Hai Welcome to Collapsible Div! Collapsible Div – Horizontal Collapse Hai Welcome to Collapsible Div! Collapsible Div – Collapse Both Ways Hai Welcome to Collapsible Div!

AC

Definition function AC(el, parent) { parent.appendChild(el); } Example Example Source <style> #extable td { padding:7px 10px; } </style> <table id=’extable’><tbody> <tr><td><input type=’button’ onclick="addRecord()" value="Add new record" class="button"></input></td></tr> </tbody></table> <script> rec=0; function addRecord() { rec++; var tr=CE(‘tr’); var td=CE(‘td’,{innerHTML:’record ‘+rec, align:’left’, style:{backgroundColor:randomColor(),color:randomColor()} }); AC(td,tr); AC(tr,GEBTN(‘tbody’,GEBI(‘extable’))[0]); } </script>

Calender

REM

Definition function REM(elem) { if (!isNull(elem)) { if (!isNull(elem.parentNode)) { elem.parentNode.removeChild(elem); } else { attrib(elem, { display: ‘none’ }); } } } Example Example Source <style> #extable td { padding:5px 5px; background-color:#EEEEEE; color:#999999; border:solid 1px #CCC } </style> <table id=’extable’> <tbody> <tr> <td colspan=2> <input type=’button’ onclick="addRecord()" value="Add new record" class="button"></input> </td> </tr> </tbody> </table> […]

AutoComplete

Normal Dropdown (Select Control) Select favourite sport Auto Complete Field Select favourite sport

isStr

Definition function isStr(str) { return (typeof (str) == ‘string’); } Example Example Source <style> #test { text-align:left; } #test2 { text-align:left; } </style> <div id=’test’></div> <div id=’test2′></div> <script> El(‘#test’).html(isStr(‘rama’)); El(‘#test2’).html(isStr(1)); </script>

Zoomy Images

Click Over Images Zoom with Same Image Zoom with Other Image  

isFn

Definition function isFn(fn) { if(isNull(fn) || fn==undefined) { return false; } return (typeof (fn) == ‘function’); } Example Example Source <style> #test { text-align:left; } #test2 { text-align:left; } </style> <div id=’test’></div> <div id=’test2′></div> <script> El(‘#test’).html(isFn(‘rama’)); El(‘#test2’).html(isFn(isStr)); </script>

WaterMark

Water Mark Text Example Name : Father Name : Focused Class Example Type Here To Search :

isNull

Definition function isNull(fn) { return (fn == null); } Example Example Source <style> #test { text-align:left; } #test2 { text-align:left; } </style> <div id=’test’></div> <div id=’test2′></div> <script> var a = ‘rama’; var b; //should be null El(‘#test’).html(isNull(a)); El(‘#test2’).html(isNull(b)); </script>