FolderBrowser extends FolderBrowser
Browser for folders. This is used with type=folder to select folders.
since TYPO3 v12, will be removed in TYPO3 v13
Table of Contents
Constants
- IDENTIFIER = 'folder'
Properties
- $backendViewFactory : BackendViewFactory
- $bparams : string
- Active with TYPO3 Element Browser: Contains the name of the form field for which this window opens - thus allows us to make references back to the main window in which the form is.
- $currentPage : int
- $displayThumbs : string|null
- $expandFolder : string|null
- $extensionConfiguration : ExtensionConfiguration
- $filelist : FileList|null
- $iconFactory : IconFactory
- $identifier : string
- $moduleStorageIdentifier : string
- $pageRenderer : PageRenderer
- $request : ServerRequestInterface|null
- $resourceDisplayMatcher : Matcher|null
- $resourceSelectableMatcher : Matcher|null
- $selectedFolder : Folder|null
- $thisScript : string
- URL of current request
- $uriBuilder : UriBuilder
- $view : ViewInterface
- $viewMode : string|null
Methods
- __construct() : mixed
- getIdentifier() : string
- Returns the identifier for the browser
- getScriptUrl() : string
- Returns the URL of the current script
- getUrlParameters() : array<string|int, string>
- Provides an array or GET parameters for URL generation
- isCurrentlySelectedItem() : bool
- Check if given value is currently the selected item
- processSessionData() : array<int, array<string|int, mixed>|bool>
- Session data for this class can be set from outside with this method.
- render() : string
- setRequest() : void
- createUri() : string
- determineScriptUrl() : mixed
- Sets the script url depending on being a module or script request
- getBackendFavicon() : string
- Retrieves configured favicon for backend with fallback.
- getBackendUser() : BackendUserAuthentication
- getBodyTagAttributes() : array<string, string>
- getBodyTagParameters() : string
- getBParamDataAttributes() : array<string, string>
- Splits parts of $this->bparams and returns needed data attributes for the Javascript
- getLanguageService() : LanguageService
- getNormalizedParams() : NormalizedParams
- getRegisteredStylesheetFolders() : array<string|int, mixed>
- Return an array of all stylesheet directories registered via $GLOBAlS['TBE_STYLES']['skins'].
- getRequest() : ServerRequestInterface
- getUriForFileName() : string
- Returns the uri of a relative reference, resolves the "EXT:" prefix (way of referring to files inside extensions) and checks that the file is inside the project root of the TYPO3 installation
- getViewModeButton() : ButtonInterface
- initialize() : void
- Loads additional JavaScript
- initSelectedFolder() : void
- Last selected folder is stored in user module session. Sanitize it to set $this->selectedFolder or keep it null.
- initVariables() : void
- loadStylesheets() : void
- Load all registered stylesheets from $GLOBALS['TBE_STYLES'] "API"
- setUpBasicPageRendererForBackend() : void
- Sets mandatory parameters for the PageRenderer.
Constants
IDENTIFIER
    public
        mixed
    IDENTIFIER
    = 'folder'
    
    
    
    
Properties
$backendViewFactory read-only
        protected
            BackendViewFactory
    $backendViewFactory
    
    
    
    
    
    
$bparams
Active with TYPO3 Element Browser: Contains the name of the form field for which this window opens - thus allows us to make references back to the main window in which the form is.
        protected
            string
    $bparams
     = ''
        Example value: "data[pages][39][bodytext]|||tt_content|"
or "data[tt_content][NEW3fba56fde763d][image]|||gif,jpg,jpeg,tif,bmp,pcx,tga,png,pdf,ai|"
Values:
0: form field name reference, eg. "data[tt_content][123][image]"
1: htmlArea RTE parameters: editorNo:contentTypo3Language
2: RTE config parameters: RTEtsConfigParams
3: allowed types. Eg. "tt_content" or "gif,jpg,jpeg,tif,bmp,pcx,tga,png,pdf,ai"
4: IRRE uniqueness: target level object-id to perform actions/checks on, eg. "data-4-pages-4-nav_icon-sys_file_reference" ("data- $pArr = explode('|', $this->bparams);
$formFieldName = $pArr[0];
$allowedTablesOrFileTypes = $pArr[3]; URL of current request Returns the identifier for the browser Returns the URL of the current script Provides an array or GET parameters for URL generation Array of values to include into the parameters Array of parameters which have to be added to URLs Check if given value is currently the selected item This method is only used in the page tree. Values to be checked Returns TRUE if the given values match the currently selected item Session data for this class can be set from outside with this method. Session data array Session data and boolean which indicates that data needs to be stored in session because it's changed HTML content Sets the script url depending on being a module or script request Retrieves configured favicon for backend with fallback. Array of body-tag attributes Splits parts of $this->bparams and returns needed data attributes for the Javascript Data attributes for Javascript Return an array of all stylesheet directories registered via $GLOBAlS['TBE_STYLES']['skins']. will be removed in TYPO3 v13.0. Use $GLOBALS['TYPO3_CONF_VARS']['BE']['stylesheets'] instead. Returns the uri of a relative reference, resolves the "EXT:" prefix
(way of referring to files inside extensions) and checks that the file is inside
the project root of the TYPO3 installation The input filename/filepath to evaluate Returns the filename of $filename if valid, otherwise blank string. Loads additional JavaScript Last selected folder is stored in user module session. Sanitize it
to set $this->selectedFolder or keep it null. Load all registered stylesheets from $GLOBALS['TBE_STYLES'] "API" Sets mandatory parameters for the PageRenderer.-
        $currentPage
        
        
                                            
    
    
    
    
    
        protected
            int
    $currentPage
     = 1
    
    
    
    
    
        $displayThumbs
        
        
                                            
    
    
    
    
    
        protected
            string|null
    $displayThumbs
     = null
    
    
    
    
    
        $expandFolder
        
        
                                            
    
    
    
    
    
        protected
            string|null
    $expandFolder
     = null
    
    
    
    
    
        $extensionConfiguration
        
        
                        read-only                    
    
    
    
    
    
        protected
            ExtensionConfiguration
    $extensionConfiguration
    
    
    
    
    
    
        $filelist
        
        
                                            
    
    
    
    
    
        protected
            FileList|null
    $filelist
     = null
    
    
    
    
    
        $iconFactory
        
        
                        read-only                    
    
    
    
    
    
        protected
            IconFactory
    $iconFactory
    
    
    
    
    
    
        $identifier
        
        
                                            
    
    
    
    
    
        protected
            string
    $identifier
     = self::IDENTIFIER
    
    
    
    
    
        $moduleStorageIdentifier
        
        
                                            
    
    
    
    
    
        protected
            string
    $moduleStorageIdentifier
     = 'media_management'
    
    
    
    
    
        $pageRenderer
        
        
                        read-only                    
    
    
    
    
    
        protected
            PageRenderer
    $pageRenderer
    
    
    
    
    
    
        $request
        
        
                                            
    
    
    
    
    
        protected
            ServerRequestInterface|null
    $request
     = null
    
    
    
    
    
        $resourceDisplayMatcher
        
        
                                            
    
    
    
    
    
        protected
            Matcher|null
    $resourceDisplayMatcher
     = null
    
    
    
    
    
        $resourceSelectableMatcher
        
        
                                            
    
    
    
    
    
        protected
            Matcher|null
    $resourceSelectableMatcher
     = null
    
    
    
    
    
        $selectedFolder
        
        
                                            
    
    
    
    
    
        protected
            Folder|null
    $selectedFolder
     = null
    
    
    
    
    
        $thisScript
        
        
                                            
    
    
        
        protected
            string
    $thisScript
     = ''
    
    
    
    
    
        $uriBuilder
        
        
                        read-only                    
    
    
    
    
    
        protected
            UriBuilder
    $uriBuilder
    
    
    
    
    
    
        $view
        
        
                                            
    
    
    
    
    
        protected
            ViewInterface
    $view
    
    
    
    
    
    
        $viewMode
        
        
                                            
    
    
    
    
    
        protected
            string|null
    $viewMode
     = null
    
    
    
    
    
            Methods
            
        
                    
        __construct()
        
    
    
    
    
    public
                    __construct(IconFactory $iconFactory, PageRenderer $pageRenderer, UriBuilder $uriBuilder, ExtensionConfiguration $extensionConfiguration, BackendViewFactory $backendViewFactory) : mixed
    Parameters
    
                    
        getIdentifier()
        
    
    
        
    public
                    getIdentifier() : string
    Return values
        string
            
        getScriptUrl()
        
    
    
        
    public
                    getScriptUrl() : string
    Return values
        string
            
        getUrlParameters()
        
    
    
        
    public
                    getUrlParameters(array<string|int, mixed> $parameters) : array<string|int, string>
    Parameters
    
                    
Return values
        array<string|int, string>
                    —
                
        isCurrentlySelectedItem()
        
    
    
        
    public
                    isCurrentlySelectedItem(array<string|int, mixed> $values) : bool
    Parameters
    
                    
Return values
        bool
                    —
                
        processSessionData()
        
    
    
        
    public
                    processSessionData(array<string|int, mixed> $data) : array<int, array<string|int, mixed>|bool>
    Parameters
    
                    
Return values
        array<int, array<string|int, mixed>|bool>
                    —
                
        render()
        
    
    
    
    
    public
                    render() : string
    Return values
        string
                    —
                
        setRequest()
        
    
    
    
    
    public
                    setRequest(ServerRequestInterface $request) : void
    Parameters
    
                    
        createUri()
        
    
    
    
    
    protected
                    createUri([array<string|int, mixed> $parameters = [] ]) : string
    Parameters
    
                    
Return values
        string
            
        determineScriptUrl()
        
    
    
        
    protected
                    determineScriptUrl() : mixed
    
        getBackendFavicon()
        
    
    
        
    protected
                    getBackendFavicon(ExtensionConfiguration $extensionConfiguration, ServerRequestInterface $request) : string
    Parameters
    
                    
Return values
        string
            
        getBackendUser()
        
    
    
    
    
    protected
                    getBackendUser() : BackendUserAuthentication
    Return values
        BackendUserAuthentication
            
        getBodyTagAttributes()
        
    
    
    
    
    protected
                    getBodyTagAttributes() : array<string, string>
    Return values
        array<string, string>
                    —
                
        getBodyTagParameters()
        
    
    
    
    
    protected
                    getBodyTagParameters() : string
    Return values
        string
            
        getBParamDataAttributes()
        
    
    
        
    protected
                    getBParamDataAttributes() : array<string, string>
    Return values
        array<string, string>
                    —
                
        getLanguageService()
        
    
    
    
    
    protected
                    getLanguageService() : LanguageService
    Return values
        LanguageService
            
        getNormalizedParams()
        
    
    
    
    
    protected
                    getNormalizedParams(ServerRequestInterface $request) : NormalizedParams
    Parameters
    
                    
Return values
        NormalizedParams
            
        getRegisteredStylesheetFolders()
        
    
    
        
    protected
                    getRegisteredStylesheetFolders() : array<string|int, mixed>
    Return values
        array<string|int, mixed>
            
        getRequest()
        
    
    
    
    
    protected
                    getRequest() : ServerRequestInterface
    Return values
        ServerRequestInterface
            
        getUriForFileName()
        
    
    
        
    protected
                    getUriForFileName(ServerRequestInterface $request, string $filename) : string
    Parameters
    
                    
Return values
        string
                    —
                
        getViewModeButton()
        
    
    
    
    
    protected
                    getViewModeButton() : ButtonInterface
    Return values
        ButtonInterface
            
        initialize()
        
    
    
        
    protected
                    initialize() : void
    
        initSelectedFolder()
        
    
    
        
    protected
                    initSelectedFolder() : void
    
        initVariables()
        
    
    
    
    
    protected
                    initVariables() : void
    
        loadStylesheets()
        
    
    
        
    protected
                    loadStylesheets(PageRenderer $pageRenderer) : void
    Parameters
    
                    
        setUpBasicPageRendererForBackend()
        
    
    
        
    protected
                    setUpBasicPageRendererForBackend(PageRenderer $pageRenderer, ExtensionConfiguration $extensionConfiguration, ServerRequestInterface $request, LanguageService $languageService) : void
    Parameters
    
                    
Search results