Remove a field from the form by the name of the field.
If there are more then 1 field with the given name, then only the first one will
be removed.

@param $name
@return Form
193315
public function removeFieldByName($name)
    {
        foreach ($this->fields as $i => $field) {
            if ($field->getName() == $name) {
                unset($this->fields[$i]);
                break;
            }
        }

        return $this;
    }
104621
public function removeParam(string $name): self
    {
        $this->parsedUri->queryString()->removeParam($name);
        return $this;
    }
570922
public function removeDirective($name)
    {
        $name = strtolower(trim($name));
        unset($this->directives[$name]);
        return $this;
    }
1001707
public function setName($name)
    {
        $this->name = $name;
        $this->setValue($this->form->getFieldValue($this->name));
        return $this;
    }
847357
public function removeElement($name)
    {

        if (isset($this->elements[$name])) {
            unset($this->elements[$name]);
        }

        return $this;
    }
247604
public function removeExtension($name)
    {
        if (isset($this->extensions[$name])) {
            unset($this->extensions[$name]);
        }

        return $this;
    }
858673
public function field($name)
  {
    return isset($this->fields[$name]) ? $this->fields[$name] : false;
  }
385146
public function delete($name)
    {
        $this->loadModel('Field.FieldInstances');
        $instance = $this->_getInstance($name);

        if ($instance && !empty($this->request->query['file'])) {
            $file = normalizePath(WWW_ROOT . "/files/{$instance->settings['upload_folder']}/{$this->request->query['file']}", DS);
            $file = new File($file);
            $file->delete();
        }

        $response = '';
        $this->viewBuilder()->layout('ajax');
        $this->title(__d('field', 'Delete File'));
        $this->set(compact('response'));
    }
466469
public function removeMatcher($name)
    {
        foreach ($this->matchers as $key => $matcher) {
            if ($name === $key) {
                unset($this->matchers[$key]);

                break;
            }
        }

        return $this;
    }
169078
public function removeIndexByName($name)
    {
        $action = DropIndex::buildFromName($this->table, $name);
        $this->actions->addAction($action);

        return $this;
    }
1352956
public function removeField($name)
    {
        foreach ($this->fields as $tab => $fields) {
            foreach ($fields as $fieldName => $field) {
                if ($fieldName == $name) {
                    unset($this->fields[$tab][$fieldName]);

                    /*
                     * Remove empty tabs from collection
                     */
                    if (!count($this->fields[$tab])) {
                        unset($this->fields[$tab]);
                    }

                    return true;
                }
            }
        }

        return false;
    }
921661
public function get($name)
	{
		$templates = $this->getTemplates();
		$form = $templates->get($name, $this->plugin->name, true);
		if ($form)
		{
			$form['title'] = $form['desc'];
			unset($form['desc']);
		}
		return $form;
	}
957758
public static function removeHeader($name)
    {
        self::$headers = array_filter(self::$headers, function ($header) use ($name) {
            return strcasecmp($header[0], $name) !== 0;
        });
    }
1246771
public function & RemoveParam ($name = '') {
		/** @var $this \MvcCore\Request */
		if ($this->params === NULL) $this->initParams();
		unset($this->params[$name]);
		return $this;
	}
571188
protected function overwriteExistingField($name)
    {
        if ($this->fields->isEmpty()) {
            return;
        }

        $this->fields = $this->fields->filter(
            function (Field $field) use ($name) {
                return $field->getName() != $name;
            }
        );
    }
10551
public function removeAction($name)
    {

        if (isset($this->actions[$name])) {
            unset($this->actions[$name]);
        }

        return $this;
    }
856276
public function removeData($name)
    {
        if (is_array($this->data)) {
            unset($this->data[$name]);
        } else {
            $this->data->$name = null;
        }

        return $this;
    }