isAnchored() public method

Tells if the form is anchored.
public isAnchored ( ) : boolean
return boolean
Example #1
0
 /**
  * @param IComponent
  * @return bool
  */
 protected function shouldSkip($component)
 {
     if ($component instanceof Controls\Button) {
         return TRUE;
     }
     if ($this->isValidating() && $this->form->isAnchored() && ($submittedBy = $this->form->isSubmitted()) && $submittedBy instanceof ISubmitterControl) {
         $controls = $submittedBy->getValidationScope();
         if ($controls === NULL) {
             return FALSE;
         }
         foreach ($controls as $control) {
             if ($control === $component) {
                 return FALSE;
             }
             if ($control instanceof Container && array_search($component, $control->getComponents(TRUE), TRUE)) {
                 return FALSE;
             }
         }
         return TRUE;
     }
     return FALSE;
 }