diff --git a/public_html/css/default/LSformElement_textarea.css b/public_html/css/default/LSformElement_textarea.css new file mode 100644 index 00000000..2af39ddc --- /dev/null +++ b/public_html/css/default/LSformElement_textarea.css @@ -0,0 +1,4 @@ +p.LSformElement_textarea { + margin: 0px; +} + diff --git a/public_html/includes/class/class.LSformElement_textarea.php b/public_html/includes/class/class.LSformElement_textarea.php index 0c94fbc1..47148289 100644 --- a/public_html/includes/class/class.LSformElement_textarea.php +++ b/public_html/includes/class/class.LSformElement_textarea.php @@ -33,6 +33,7 @@ class LSformElement_textarea extends LSformElement { var $fieldTemplate = 'LSformElement_textarea_field.tpl'; + var $fieldTemplateExtraClass = ''; /** * Retourne les infos d'affichage de l'élément @@ -52,7 +53,13 @@ class LSformElement_textarea extends LSformElement { ); LSsession :: addJSscript('LSformElement_textarea.js'); } - $return['html'] = $this -> fetchTemplate(); + LSsession :: addCssFile('LSformElement_textarea.css'); + $return['html'] = $this -> fetchTemplate( + NULL, + array ( + 'LSformElement_textarea_extra' => $this -> fieldTemplateExtraClass + ) + ); return $return; } } diff --git a/public_html/templates/default/LSformElement_textarea_field.tpl b/public_html/templates/default/LSformElement_textarea_field.tpl index 637571cd..ff4b1c7f 100644 --- a/public_html/templates/default/LSformElement_textarea_field.tpl +++ b/public_html/templates/default/LSformElement_textarea_field.tpl @@ -1,5 +1,5 @@ {if $freeze} -{if $value}{$value}{else}{$noValueTxt}{/if} +{if $value}
{$value}
{else}{$noValueTxt}{/if} {else} {/if}