Pages: 1
Author Topic: difference between RulesChecking and DOMEnforceValid  (Read 2705 times)

Posts: 43

« on: April 26, 2010, 12:37:00 PM »

I think that both cRulesChecking and DOMEnforceValid an turn on/off rules checking.
so, is there difference between two?
Derek Read
Program Manager (XMetaL)

Posts: 2621

« Reply #1 on: April 26, 2010, 01:51:16 PM »

Quote from: Programmer's Guide
By default, rules checking stays on during DOM operations that modify the document. Therefore, operations that would create an invalid document are disallowed. This property returns and sets whether rules checking can be turned off in the document during DOM operations.

Perhaps this would be better stated as "This property allows RulesChecking to be temporarily suspended when DOM operations are being performed. If your DOM operations leave the document in an invalid state then RulesChecking will be turned off, or left off if RulesCheck was already turned off. If your DOM operations leave the document in a valid state then RulesChecking will be left in the state it was in prior to those DOM operations having been performed."

This is different from you deciding up front that you will be putting the document into an invalid state, turning RulesChecking off, manipulating the document, and then deciding to turn RulesChecking back on.
Pages: 1
Jump to:  

email us