求助  JavaScript 
在IE下  setAttribute(参数一,参数二) 参数二为object
在foxfire 下setAttribute(参数一,参数二)参数二为string

解决方案 »

  1.   

    可以参考这里attribute/property的部分
      

  2.   

    setAttribute Method 
    Syntaxobject.setAttribute(sAttrName, vAttrValue)
    ParameterssAttrName Required. String that specifies the name of the persistent attribute. 
    vAttrValue Required. Variant that specifies the value of the persistent attribute. Return ValueNo return value.ResIf the specified attribute is not already present, the setAttribute method adds the attribute to the object and sets the value.The sAttrName value is not case sensitive.This method requires an object participating in persistence, where that object has a class name equal to the desired persistence behavior. An ID is required for the userData and saveSnapshot behaviors, and recommended for the saveHistory and saveFavorite behaviors. This method overrides the DHTML setAttribute method. 
      

  3.   

    IE下不是 FF下是为啥区别介么大 呜呜
      

  4.   

    看懂了一点 IE 跟 FF下attribute/property的区别 其他还是很茫然 看来也要找点书啃啃了