19declare(strict_types=1);
37 if (
null === $userDefinedFieldPlaceHolderDescriptionObject) {
43 $userDefinedPlaceholderHtmlDescription = $userDefinedFieldPlaceHolderDescriptionObject->getPlaceholderDescriptions();
48 $this->placeholder = [
49 'CERTIFICATE_ID' =>
$language->
txt(
'certificate_ph_cert_id'),
51 'USER_FULLNAME' =>
$language->
txt(
'certificate_ph_fullname'),
52 'USER_FIRSTNAME' =>
$language->
txt(
'certificate_ph_firstname'),
53 'USER_LASTNAME' =>
$language->
txt(
'certificate_ph_lastname'),
55 'USER_SALUTATION' =>
$language->
txt(
'certificate_ph_salutation'),
56 'USER_BIRTHDAY' =>
$language->
txt(
'certificate_ph_birthday'),
57 'USER_INSTITUTION' =>
$language->
txt(
'certificate_ph_institution'),
58 'USER_DEPARTMENT' =>
$language->
txt(
'certificate_ph_department'),
59 'USER_STREET' =>
$language->
txt(
'certificate_ph_street'),
61 'USER_ZIPCODE' =>
$language->
txt(
'certificate_ph_zipcode'),
62 'USER_COUNTRY' =>
$language->
txt(
'certificate_ph_country'),
63 'USER_MATRICULATION' =>
$language->
txt(
'certificate_ph_matriculation'),
68 $this->placeholder = array_merge($this->placeholder, $userDefinedPlaceholderHtmlDescription);
78 if (
null === $template) {
79 $template =
new ilTemplate(
'tpl.default_description.html',
true,
true,
'components/ILIAS/Certificate');
82 $template->setVariable(
'PLACEHOLDER_INTRODUCTION', $this->
language->txt(
'certificate_ph_introduction'));
84 $template->setCurrentBlock(
'items');
85 foreach ($this->placeholder as
$id => $caption) {
86 $template->setVariable(
'ID',
$id);
87 $template->setVariable(
'TXT', $caption);
88 $template->parseCurrentBlock();
91 return $template->get();
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Collection of basic placeholder values that can be used.
createPlaceholderHtmlDescription(?ilTemplate $template=null)
This method is different then the 'getPlaceholderValues' method, this method is used to create a plac...
readonly ilLanguage $language
getPlaceholderDescriptions()
This method MUST return an array containing an array with the the description as array value.
__construct(ilLanguage $language, Profile $profile, ?ilUserDefinedFieldsPlaceholderDescription $userDefinedFieldPlaceHolderDescriptionObject=null)
loadLanguageModule(string $a_module)
Load language module.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
special template class to simplify handling of ITX/PEAR