2006-04-24
jsReq
I wanted to tell the user that they need JavaScript, but obviously only if they don’t already have it enabled.
The following is a very crude script which uses the very fact that JS is available to hide the requirement notice…
HTML:
JS:
-
function removeElementById(eleId) {
-
eleId = document.getElementById(eleId);
-
if (eleId.parentNode && eleId.parentNode.removeChild) {
-
eleId.parentNode.removeChild(eleId);
-
}
-
}
-
removeElementById(“jsRequiredDiv”);