$quotas=array();
foreach ($this -> values as $value) {
- if (ereg('([0-9]*)S',$value,$regs)) {
+ if (ereg('([0-9]*)'.$this -> getSuffix(),$value,$regs)) {
$infos = array(
'size' => $regs[1]
);
)
);
}
-
+
+ /**
+ * Return suffix value
+ *
+ * @retval string Suffix value
+ **/
+ function getSuffix() {
+ if(isset($this -> params['html_options']['suffix'])){
+ return strval($this -> params['html_options']['suffix']);
+ }
+ else {
+ return "S";
+ }
+ }
+
/**
* Recupère la valeur de l'élement passée en POST
*
if (isset($_POST[$this -> name.'_sizeFact'][$key]) && ($_POST[$this -> name.'_sizeFact'][$key]!=1)) {
$f = $_POST[$this -> name.'_sizeFact'][$key];
}
- $return[$this -> name][$key] = ($val*$f).'S';
+ $return[$this -> name][$key] = ($val*$f).$this->getSuffix();
}
}
return true;