Programatorul de la A la ZI Programatorul de la A la ZI V1.2 Beta - In curand se va face lansare.
 
 
 Any code of your own that you haven't looked at for six or more months might as well have been written by someone else.Eagleson's Law 
 
 
Seteaza un atribut pentru un obiect ID. - Cod Sursa
Descriere
Seteaza un atribut pentru un obiect ID.

Cod      - Testeaza 

function SetAttribute(object, attrName, attrValue) {    if (document.getElementById) {        if (object.hasAttribute) {            if (object.hasAttribute(attrName)) {                if (object.getAttribute) {                    if (object.getAttribute(attrName) == attrValue) {                        return true;                    }                }                if (object.removeAttribute) {                    object.removeAttribute(attrName);                }            }        }        if (object.setAttribute) {            object.setAttribute(attrName, attrValue);            return true;        }        var attr = document.createAttribute(attrName);        if (attr) {            attr.nodeValue = attrValue;            if (object.setAttributeNode) {                object.setAttributeNode(attr);                return true;            }        }    }    return false;}function SetAttributeByID(objectID, attrName, attrValue) {    if (document.getElementById) {        var object = document.getElementById(objectID);        if (object) {            return SetAttribute(object, attrName, attrValue);        }    }    return false;}

V1.2 Beta - In curand se va face lansare.

Copyright 2007 © . Toate drepturile rezervate .