Actions

J1.5

Difference between revisions of "Folderlist parameter type"

From Joomla! Documentation

m (Added more categorisations because this page is generic.)
(Fix red links)
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
[[Image:Params.folderlist.jpg|right]]
 
[[Image:Params.folderlist.jpg|right]]
The '''folderlist''' parameter type provides a drop down list of folders from a specfied directory. If the parameter has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.  
+
 
 +
{{Ambox|type=notice|text=[[Parameter|Parameters]] have been superseded by [[Form field|form fields]] in Joomla! 1.6. You may want to use the corresponding [[Folderlist form field type]].}}
 +
 
 +
The '''folderlist''' parameter type provides a drop down list of folders from a specfied directory. If the parameter has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.  
  
 
By default, the first item on the list is '- Do not use -' (which is translatable) and is given the value '-1' and this is followed by '- Use default -' (also translatable) given the value '0'.
 
By default, the first item on the list is '- Do not use -' (which is translatable) and is given the value '-1' and this is followed by '- Use default -' (also translatable) given the value '0'.
Line 10: Line 13:
 
* '''default''' (optional) is the default folder name.
 
* '''default''' (optional) is the default folder name.
 
* '''description''' (optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.
 
* '''description''' (optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.
* '''filter''' (optional) is a regular expression string which is used to filter the list of folders selected for inclusion in the drop-down list. If omitted, all folders in the directory are included. The filter argument expression is applied before the exclude argument expression.  For information on constructing regular expressions see [[Regular expressions in parameter arguments]].
+
* '''filter''' (optional) is a regular expression string which is used to filter the list of folders selected for inclusion in the drop-down list. If omitted, all folders in the directory are included. The filter argument expression is applied before the exclude argument expression.  For information on constructing regular expressions see [[Regular expressions in parameter arguments]].
 
* '''exclude''' (optional) is a regular expression string which is used to exclude folders from the list.  The exclude argument expression is applied after the filter argument expression.  For information on constructing regular expressions see [[Regular expressions in parameter arguments]].
 
* '''exclude''' (optional) is a regular expression string which is used to exclude folders from the list.  The exclude argument expression is applied after the filter argument expression.  For information on constructing regular expressions see [[Regular expressions in parameter arguments]].
* '''hide_none''' (optional) is a Boolean argument. If true, the '- Do not use -' item is omitted from the drop-down list.
+
* '''hide_none''' (optional) is a Boolean argument. If true, the '- Do not use -' item is omitted from the drop-down list.
* '''hide_default''' (optional) is a Boolean argument. If true, the '- Use default -' item is omitted from the drop-down list.
+
* '''hide_default''' (optional) is a Boolean argument. If true, the '- Use default -' item is omitted from the drop-down list.
  
 
Example XML parameter definition:
 
Example XML parameter definition:
Line 19: Line 22:
 
<noinclude>
 
<noinclude>
 
=== See also ===
 
=== See also ===
* [[Filelist parameter type]]
+
* [[J1.5:Filelist parameter type|Filelist parameter type]]
* [[Imagelist parameter type]]
+
* [[J1.5:Imagelist parameter type|Imagelist parameter type]]
* [[Standard parameter types|Full list of standard parameter types]]
+
* [[J1.5:Standard parameter types|List of standard parameter types]]
[[Category:Components]][[Category:Modules]][[Category:Plugins]][[Category:Templates]][[Category:Development]]</noinclude>
+
</noinclude>
 +
[[Category:Archived version Joomla! 1.5|{{PAGENAME}}]]

Latest revision as of 03:28, 11 June 2013

Replacement filing cabinet.png
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.
Params.folderlist.jpg

The folderlist parameter type provides a drop down list of folders from a specfied directory. If the parameter has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.

By default, the first item on the list is '- Do not use -' (which is translatable) and is given the value '-1' and this is followed by '- Use default -' (also translatable) given the value '0'.

  • type (mandatory) must be folderlist.
  • name (mandatory) is the unique name of the parameter.
  • label (mandatory) (translatable) is the descriptive title of the field.
  • directory (mandatory) is the filesystem path to the directory containing the folders to be listed.
  • default (optional) is the default folder name.
  • description (optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.
  • filter (optional) is a regular expression string which is used to filter the list of folders selected for inclusion in the drop-down list. If omitted, all folders in the directory are included. The filter argument expression is applied before the exclude argument expression. For information on constructing regular expressions see Regular expressions in parameter arguments.
  • exclude (optional) is a regular expression string which is used to exclude folders from the list. The exclude argument expression is applied after the filter argument expression. For information on constructing regular expressions see Regular expressions in parameter arguments.
  • hide_none (optional) is a Boolean argument. If true, the '- Do not use -' item is omitted from the drop-down list.
  • hide_default (optional) is a Boolean argument. If true, the '- Use default -' item is omitted from the drop-down list.

Example XML parameter definition:

<param name="myfolder" type="folderlist" default="" label="Select a folder" directory="administrator" filter="" exclude="" stripext="" />

See also