public function removeElement($name)
    {
        $returnValue = false;

		foreach($this->elements as $index => $element){
			if($element->getName() == $name){
				unset($this->elements[$index]);
				$groupName = $this->getElementGroup($name);
				if(!empty($groupName)){
					if(isset($this->groups[$groupName]['elements'][$name])){
						unset($this->groups[$groupName]['elements'][$name]);
					}
				}
				$returnValue = true;
			}
		}

        return $returnValue;
    }