TSconfig

1.3.2. ->MOD

Configuration for backend modules. Generally the syntax is [module_name].[property]. The module name is defined in the conf.php files for the module.

Blinding Function Menu options in Backend Modules

Most of the modules in TYPO3 has a "function menu" selector box and this menu is usually configurable so you are able to remove menu items in specific sections of the page tree (or by overriding via User TSconfig, you could disable an option totally for a specific user/group).

In this case the main menu of the Web>Info module looks like this:

 


By adding this Page TSconfig we can remove the "Page TSconfig" item:

  mod.web_info.menu.function {
    tx_infopagetsconfig_webinfo = 0
  }

The function menu will now look like this:

 


The 'Page TSconfig' option is simply disabled by setting this Page TSconfig!

 

All you need to know in order to disable function menu items in the backend modules is, which modules support it and what the key of the menu item is (in the above example it was 'tx_infopagetsconfig_webinfo'). Modules extending the class "t3lib_SCbase" will most likely provide this out-of-the-box since it's a part of the base class in t3lib_SCbase::menuConfig().

 

Examples from the TYPO3 core is listed in the table below (Testsite package):

 

Property:

-

Description:

web_layout.menu.function

 

Web > Page module

 


 

Option tags:

 

  <select name="SET[function]">
      <option value="1">Columns</option>
      <option value="0">QuickEdit</option>
      <option value="2">Languages</option>
      <option value="3">Page information</option>
  </select>

Example:

 

    # Disables all items except the "QuickEdit" item:
  mod.web_layout.menu.function {
    1 = 0
    2 = 0
    3 = 0
  }

web_info.menu.function

 

Web > Info module

 


Option tags:

 

  <select name="SET[function]">
      <option value="tx_cms_webinfo_page">Pagetree overview</option>
      <option value="tx_belog_webinfo">Log</option>
      <option value="tx_infopagetsconfig_webinfo">Page TSconfig</option>
      <option value="tx_cms_webinfo_hits">Hit Statistics</option>
      <option value="tx_indexedsearch_modfunc1">Indexed search</option>
  </select>

Example:

 

    # Disables the item "Hit Statistics":
  mod.web_info.menu.function {
    tx_cms_webinfo_hits = 0
  }

web_func.menu.function

 

Web > Functions module

 


Option tags:

 

  <select name="SET[function]">
      <option value="tx_funcwizards_webfunc">Wizards</option>
  </select>

web_func.menu.wiz

 

Web > Functions module, Wizards sub module

This is the 2nd-level Function Menu in the Web > Functions module. Instead of the "function" key of the main menu it just uses the key "wiz" instead.

 


Option tags:

 

  <select name="SET[wiz]">
      <option value="tx_wizardcrpages_webfunc_2">Create multiple pages</option>
      <option value="tx_wizardsortpages_webfunc_2">Sort pages</option>
  </select>

Example:

 

    # Disables the sub-item "Create multiple pages":
  mod.web_func.menu.wiz {
    tx_wizardcrpages_webfunc_2 = 0
  }

web_ts.menu.function

 

Web > Template module

 


 

Option tags:

 

  <select name="SET[function]">
      <option value="tx_tstemplateceditor">Constant Editor</option>
      <option value="tx_tstemplateinfo">Info/Modify</option>
      <option value="tx_tstemplateobjbrowser">TypoScript Object Browser</option>
      <option value="tx_tstemplateanalyzer">Template Analyzer</option>
      <option value="tx_tstemplatestyler_modfunc1">CSS Styler</option>
  </select>

user_task.menu.function

 

User > Task Center

This is slightly different because the Task Center does not provide a selector box function menu. But behind the scene it uses the same functionality of saving "states" and therefore you can also blind items in the Task Center.

There is one tricky thing thought: The Task Center is not depending on a page in the page tree! So you either have to set default Page TSconfig or User TSconfig to blind options here!

 


 

Keys are:

 

tx_sysnotepad = Quick Note
tx_taskcenterrecent = Recent Pages
tx_taskcenterrootlist = Web>List module / root
tx_taskcentermodules = Plugins
tx_sysaction = Actions
tx_systodos = Tasks

 

Example:

Set this as User TSconfig:

 

    # Task Center configuration:
  mod.user_task.menu.function {
      # Disable "Recent Pages" display:
    tx_taskcenterrecent  = 0
      # Disable "Action" list
    tx_sysaction = 0
  }

[page:mod; beuser:mod]

 

 

Since function menu items can be provided from extensions it is not possible to create a complete list of menu keys. (The list in the table above is what is installed by default in the Testsite package.)

Therefore, if you want to blind a menu item the only sure way of doing it is to look in the HTML source of the backend module and find the selector box with the function menu and extract the key from the <option> tags. This listing is a cleaned-up version of a function menu. The keys are the values of the option tags:

 

  <select>
      <option value="tx_cms_webinfo_page">Pagetree overview</option>
      <option value="tx_belog_webinfo">Log</option>
      <option value="tx_infopagetsconfig_webinfo">Page TSconfig</option>
  </select>

As you can see this is where the key for the example before was found:

  mod.web_info.menu.function {
    tx_infopagetsconfig_webinfo = 0
  }

 

WARNING:

Blinding Function Menu items is not hardcore access control! All it does is to hide the possibility of accessing that module functionality from the interface. It might be possible for users to hack their way around it and access the functionality anyways. You should use the option of blinding elements mostly to remove otherwise distracting options.

Overriding Page TSconfig with User TSconfig

In all standard modules the Page TSconfig values of the "mod." branch may be overridden by the same branch of values set for the backend user.

To illustrate this feature lets consider the case from above where a menu item in the Web>Info module was disabled in the Page TSconfig by this value:

  mod.web_info.menu.function {
    tsconf = 0
  }

If however we set this configuration in the TSconfig of a certain backend user (eg. the admin user), that user would still be able to select this menu item because the value of his User TSconfig overrides the same value set in the Page TSconfig:

  mod.web_info.menu.function {
    tsconf = 1
  }

Here's another example where the value 'mod.web_layout.editFieldsAtATime' has been overridden by User TSconfig to the value '5' instead of '1'. The image shows you how to check the Page TSconfig (the upper image) and also see if User TSconfig of the current user (the logged in user) has altered anything from this configuration (lower image):

 


 

Shared options for modules (mod.SHARED):

Property:

Data type:

Description:

Default:

colPos_list

(list of integers, blank = don't do anything.)

This option lets you specify which columns of tt_content elements should be displayed in the 'Columns' view of the modules, in particular Web>Page.

By default there are four columns, Left, Normal, Right, Border. However most websites use only the Normal column, maybe another also. In that case the remaining columns are not needed. By this option you can specify exactly which of the columns you want to display.

Each column has a number which ultimately comes from the configuration of the table tt_content, field 'colPos' found in the tables.php file. This is the values of the four default columns:

Left: 1

Normal: 0

Right: 2

Border: 3

 

Example:

This results in only the Normal and Border column being displayed:

 

  mod.SHARED.colPos_list = 0,3

 

defaultLanguageLabel

string

Alternative label for "Default" when language labels are shown in the interface.

 

Used on Web>List, Web>Page and TemplaVoilas page module.

 

defaultLanguageFlag

string

Flag icon filename from gfx/flags/ for default language

 

User in Web>List and TemplaVoila page module.

 

[page:mod.SHARED; beuser:mod.SHARED]

 

Web>Page (mod.web_layout):

Property:

Data type:

Description:

Default:

tt_content.colPos_list

(list of integers, blank = don't do anything.)

See mod.SHARED.colPos_list for details.

If non-blank, this list will override the one set by  mod.SHARED.colPos_list.

 

Example:

This results in only the Normal and Border column being displayed:

 

  mod.web_layout.tt_content.colPos_list = 0,3

 

tt_content.fieldOrder

list of field names from tt_content table

This allows you to specify (and thereby overrule) the preferred order of the fieldnames of the "Quick Edit" editing forms of the tt_content table (Content Elements). Just specify the list of fields, separated by comma. Then these fields will be listed first and all remaining fields thereafter in their original order.

 

Example:

This results in the 'Text' field and thereafter 'Header' field being display as the very first fields instead of the 'Type' field.

 

  mod.web_layout.tt_content {
    fieldOrder = bodytext, header
  }

 

editFieldsAtATime

int+

Specifies the number of subsequent content elements to load in the editform when clicking the editicon of a content element in the 'Columns' view of the module.

 

Example:

 

  mod.web_layout {
    editFieldsAtATime = 2
  }

1

noCreateRecordsLink

boolean

If set, the link in the bottom of the page, "Create new record", is hidden.

 

QEisDefault

boolean

If set, then the QuickEditor is the first element in the Function Menu in the top of the menu in Web>Page

 

disableSearchBox

boolean

Disables the search box in Columns view.

 

disableBigButtons

boolean

Disables the large buttons in top of the Columns view.

 

These are the buttons that are hidden by this option:

 


 

disableAdvanced

boolean

Disables the clear cache advanced function  in the bottom of the page in the module, including the "Create new record" link.

 

disableNewContentElementWizard

boolean

Disables the fact that the new-content-element icons links to the content element wizard and not directly to a blank "NEW" form.

 

defaultLanguageLabel

string

Alternative label for "Default" when language labels are shown in the interface.

 

Overrides the same property from mod.SHARED if set.

 

defLangBinding

boolean

If set, translations of content elements are bound to the default record in the display. This means that within each column with content elements any translation found for exactly the shown default content element will be shown in the language column next to.

 

This display mode should be used depending on how the frontend is configured to display localization. The frontend must display localized pages by selecting the default content elements and for each one overlay with a possible translation if found.

 

disableIconToolbar

boolean

Disables the topmost icon toolbar with the "view"-Icon and the icon

toolbar below.

 

[page:mod.web_layout; beuser:mod.web_layout]

 

Web>List (mod.web_list):

Property:

Data type:

Description:

Default:

noCreateRecordsLink

boolean

If set, the link in the bottom of the page, "Create new record", is hidden.

 

Example:

 

  mod.web_list {
    noCreateRecordsLink = 1
  }

 

alternateBgColors

boolean

If set, the background colors of elements will alternate.

 

Example:

 

  mod.web_list {
    alternateBgColors = 1
  }

The result is alternating background colors for each element:

 


 

disableSingleTableView

boolean

If set, then the links on the table titles which shows a single table listing only will not be available (including sorting links on columns titles, because these links jumps to the table-only view).

 

listOnlyInSingleTableView

boolean

If set, then records will be listed only when the single table view is enabled. This is very practical for pages containing many records from many tables!

 

Example:

 

  mod.web_list {
    listOnlyInSingleTableView = 1
  }

The result will be that records from tables are listed only in the single-table mode and the default view will just show number of table records in page and the table description if available:


 

hideTables

list of table names

Hide these tables in record listings (comma-separated)

 

allowedNewTables

list of tablenames

If this list is set, then only tables listed here will have a link to "create new" in the page and subpages.

 

This also affects "db_new.php" (the display of "Create new record")

Note: Technically records can be created (eg. by copying/moving), so this is "pseudo security". The point is to reduce the number of options for new records visually.

 

Example:

 

  mod.web_list {
    allowedNewTables = pages, tt_news
  }

Only pages and tt_news  table elements will be linked to in the New record screen:

 


 

newWizards

boolean

If set, then the new-link over the control panel of the pages and tt_content listings in the List module will link to the wizards and not create a record in the top of the list.

 

showClipControlPanelsDespiteOfCMlayers

boolean

If set, then the control- and clipboard panels of the module is shown even if the context-popups (ClickMenu) are available. Normally the control- and clipboard panels are disabled (unless extended mode is set) in order to save bandwidth.

 

newPageWiz.overrideWithExtension

newContentWiz.overrideWithExtension

string

If set to an extension key, (eg. "templavoila") then the "mod1/index.php" file of that extension will be used for creating new elements on the page. "newContentWiz" will likewise use the "mod1/db_new_content_el.php" for creating new content elements.

 

Also see "options.overridePageModule"

 

clickTitleMode

string

Keyword which defines what happens when a user clicks the title in the list.

 

Default is that pages will go one level down while other records have no link at all.

 

Keywords:

edit = Edits record

info = Shows information

show = Shows page/content element in frontend

 

[page:mod.web_list; beuser:mod.web_list]

 

Web>View (mod.web_view):

Property:

Data type:

Description:

Default:

type

int+

Enter the value of the &type parameter passed to the webpage.

 

Example:

By this configuration frontend pages will be shown with "index.php?id=123&type=1" from the Web > View module:

 

  mod.web_view {
    type = 1
  }

 

[page:mod.web_view; beuser:mod.web_view]

 

Tools>Extension Manager (mod.tools_em):

Property:

Data type:

Description:

Default:

allowTVlisting

boolean

If set the Technical and Validation listings are available in the EM. Those will evaluate ALL available extensions and that can take many seconds (up to 30) depending on number of extensions.

 

Example:

 

  mod.tools_em.allowTVlisting = 1

Enables these options in the Extension Manager:

 


 

[beuser:mod.tools_em]

 

Edit document 'module' (mod.xMOD_alt_doc):

Property:

Data type:

Description:

Default:

disableDocSelector

boolean

If set, the document selector is disabled

 

Example:

 

  mod.xMOD_alt_doc {
    disableDocSelector = 1
    disableCacheSelector = 1
  }

The result is that both the document and cache action selector is hidden in the form page:

 


(The interesting part is what is missing...)

 

disableCacheSelector

boolean

If set, the cache/save/close selector is disabled.

 

See example above.

 

[page:mod.xMOD_alt_doc; beuser:mod.xMOD_alt_doc]

 

To top


Valid XHTML 1.0!