Function Arguments
- srcImg:-the Default Image url
- mouseOverImg :- the mouse over Image url
var but=document.createElement("IMG");
but.src=srcImg;
but.onmouseover=new function(){but.src=mouseOverImg;}
return but;
}
2.HTML Button Mouse Listener.
Function Arguments
- but:-The HTML button Object
- mouseOverImg :- the mouse over Image url
- mouseOutImg:- the mouse out Image url
function buttonMouseListener(but,mouseOverImg,mouseOutImg){
but.onmouseover = function(){but.src=mouseOverImg;}
but.onmouseout = function(){but.src=mouseOutImg;}
}
3.Create HTML CheckBox
Function Arguments
- The id of the checkBox.
var checkBox = document.createElement("input");
checkBox.type = "checkbox"; // set type
checkBox.id = id;
return checkBox;
}
No comments:
Post a Comment