protected function updateFolderName(HTTPRequest $request)
    {
        // check if allowed to select folder
        if (!$this->getCanSelectFolder()) {
            return;
        }

        // Get path from upload
        $folderID = $request->requestVar("{$this->Name}/folder");
        $path = $this->folderPathFromID($folderID);
        if ($path !== false) {
            $this->setFolderName($path);
            $this->selectField->setValue($folderID);
        }
    }