Actions

J1.5

Difference between revisions of "Textarea parameter type"

From Joomla! Documentation

m (Added more categorisations because this page is generic.)
m (Default value of textarea parameter type is not translatable)
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
[[Image:Params.textarea.jpg|right]]
 
[[Image:Params.textarea.jpg|right]]
The '''textarea''' parameter type provides a text area for entry of multi-line text.  If the parameter has a value saved, this value is displayed when the page is first loaded.  If not, the default value (if any) is selected.
 
  
<font color="red">[[[ Note that there is currently a bug such that the field cannot handle more than one line of data – see Tracker #12261. ]]]</font>
+
{{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 [[Textarea form field type]].}}
 +
 
 +
The '''textarea''' parameter type provides a text area for entry of multi-line text.  If the parameter has a value saved, this value is displayed when the page is first loaded.  If not, the default value (if any) is selected.
  
 
* '''type''' (mandatory) must be ''textarea''.
 
* '''type''' (mandatory) must be ''textarea''.
Line 9: Line 10:
 
* '''rows''' (mandatory) is the height of the visible text area in lines.  If omitted the width is determined by the browser.  The value of rows does not limit the number of lines that may be entered.
 
* '''rows''' (mandatory) is the height of the visible text area in lines.  If omitted the width is determined by the browser.  The value of rows does not limit the number of lines that may be entered.
 
* '''cols''' (mandatory) is the width of the visible text area in characters.  If omitted the width is determined by the browser.  The value of cols does not limit the number of characters that may be entered.
 
* '''cols''' (mandatory) is the width of the visible text area in characters.  If omitted the width is determined by the browser.  The value of cols does not limit the number of characters that may be entered.
* '''default''' (optional) (translatable) is the default value.
+
* '''default''' (optional) (not translatable) is the default value.
 
* '''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.
 
* '''class''' (optional)  is a CSS class name for the HTML form field.  If omitted this will default to 'text_area'.
 
* '''class''' (optional)  is a CSS class name for the HTML form field.  If omitted this will default to 'text_area'.
Line 16: Line 17:
 
<source lang="xml"><param name="mytextarea" type="textarea" default="default" label="Enter some text" description="" rows="10" cols="5" /></source>
 
<source lang="xml"><param name="mytextarea" type="textarea" default="default" label="Enter some text" description="" rows="10" cols="5" /></source>
 
<noinclude>
 
<noinclude>
 +
=== Tips ===
 +
* If you need to line break just encode <code>&lt;br /&gt;</code> in the XML config file like this: <code>&amp;lt;br /&amp;gt;</code>
 
=== See also ===
 
=== See also ===
 
* [[Text parameter type]]
 
* [[Text parameter type]]
* [[Standard parameter types|Full list of standard parameter types]]
+
* [[Standard parameter types|List of standard parameter types]]
[[Category:Components]][[Category:Modules]][[Category:Plugins]][[Category:Templates]][[Category:Development]]</noinclude>
+
[[Category:Standard parameter types]]</noinclude>

Revision as of 13:29, 25 March 2012

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.textarea.jpg

The textarea parameter type provides a text area for entry of multi-line text. If the parameter has a value saved, this value is displayed when the page is first loaded. If not, the default value (if any) is selected.

  • type (mandatory) must be textarea.
  • name (mandatory) is the unique name of the parameter.
  • label (mandatory) (translatable) is the descriptive title of the field.
  • rows (mandatory) is the height of the visible text area in lines. If omitted the width is determined by the browser. The value of rows does not limit the number of lines that may be entered.
  • cols (mandatory) is the width of the visible text area in characters. If omitted the width is determined by the browser. The value of cols does not limit the number of characters that may be entered.
  • default (optional) (not translatable) is the default value.
  • description (optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.
  • class (optional) is a CSS class name for the HTML form field. If omitted this will default to 'text_area'.

Example XML parameter definition:

<param name="mytextarea" type="textarea" default="default" label="Enter some text" description="" rows="10" cols="5" />

Tips

  • If you need to line break just encode <br /> in the XML config file like this: &lt;br /&gt;

See also