Castle.MonoRail.Framework.Helpers.FormHelper.TextAreaValue C# (CSharp) Method

TextAreaValue() public method

Generates a textarea element with a specified value.
public TextAreaValue ( string target, object value, IDictionary attributes ) : string
target string The target to base the element name on.
value object The value to apply to the field.
attributes IDictionary Attributes for the FormHelper method and for the html element it generates
return string
		public string TextAreaValue(string target, object value, IDictionary attributes)
		{
			target = RewriteTargetIfWithinObjectScope(target);

			value = value == null ? "" : HtmlEncode(value.ToString());

			string id = CreateHtmlId(target);

			ApplyValidation(InputElementType.Text, target, ref attributes);

			return String.Format("<textarea id=\"{0}\" name=\"{1}\" {2}>{3}</textarea>",
				id, target, GetAttributes(attributes), FormatIfNecessary(value, attributes));
		}