/** * Decode from Json to PHP * * @param string|array $field The value to decode (or if alreay is an array already) * @param string $onEmptyValue Defines the value if the language could not be found and a value will be returns, this value will be used. * @return array returns an array with decoded field value */ public function i18nFieldDecode($value, $onEmptyValue = '') { return I18n::decode($value, $onEmptyValue); }
/** * This is what will be returned when the property is requested in the frontend. * * You can override this function in order to provide your own output logic. * * @return mixed */ public function getValue() { if ($this->i18n) { $this->value = I18n::decode($this->value); } return $this->value; }
/** * Get the array with all captions from the filemanager global "captions" definition for all provided languages * * @return array Get the array with all captions from the filemanager global "captions" definition for all provided languages */ public function getCaptionArray() { return I18n::decode($this->itemArray['caption']); }